package interfaz;

import dominio.*;
import integracion.*;
import java.awt.Color;
import java.awt.Component;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import java.awt.event.MouseAdapter;
import java.awt.event.MouseEvent;
import java.io.IOException;
import java.sql.Date;
import java.sql.SQLException;
import java.sql.Time;
import java.util.Iterator;
import java.util.List;
import java.util.Vector;
import java.util.logging.Level;
import java.util.logging.Logger;
import javax.swing.JOptionPane;
import javax.swing.table.DefaultTableModel;

public class InformacionSistema2 extends javax.swing.JFrame {

    ControlProveedor controlProveedor;
    ControlFactura controlFactura;
    ControlCuota controlCuota;
    ControlOrdenCompra controlOrdenCompra;
    ControlPago controlPago;
    ControlRecibo controlRecibo;
    ControlEvento controlEvento;
    ControlCotizacion controlCotizacion;
    ControlEmpleado controlEmpleado;
    ControlClienteCompania controlClienteCompania;
    ControlClienteParticular controlClienteParticular;
    ControlUso controlUso;
    ControlInsumoInventario controlInsumoInventario;
    ControlInsumo controlInsumo;
    NuevaCotizacion NuevaCotizacion;
    private Component aviso;
    private Color Color;

    public InformacionSistema2() {
        initComponents();
        this.setLocation(210, 10);
        this.validarCampos();
    }

    @SuppressWarnings("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {
        bindingGroup = new org.jdesktop.beansbinding.BindingGroup();

        buttonGroup1 = new javax.swing.ButtonGroup();
        jTabbedPane1 = new javax.swing.JTabbedPane();
        jPanel3 = new javax.swing.JPanel();
        jPanel15 = new javax.swing.JPanel();
        idEventosSegundaCuota = new javax.swing.JComboBox();
        jLabel53 = new javax.swing.JLabel();
        jLabel1 = new javax.swing.JLabel();
        jLabel3 = new javax.swing.JLabel();
        jLabel5 = new javax.swing.JLabel();
        fechaCotizacionLabel = new javax.swing.JLabel();
        jPanel16 = new javax.swing.JPanel();
        jLabel56 = new javax.swing.JLabel();
        jLabel4 = new javax.swing.JLabel();
        fechaLabel = new javax.swing.JLabel();
        ejecutivoEncargadoLabel = new javax.swing.JLabel();
        jLabel34 = new javax.swing.JLabel();
        horaInicio = new javax.swing.JLabel();
        jLabel36 = new javax.swing.JLabel();
        horaFin = new javax.swing.JLabel();
        jLabel20 = new javax.swing.JLabel();
        duracionEvento = new javax.swing.JLabel();
        jLabel122 = new javax.swing.JLabel();
        jLabel13 = new javax.swing.JLabel();
        lugarEvento = new javax.swing.JLabel();
        jPanel17 = new javax.swing.JPanel();
        jLabel57 = new javax.swing.JLabel();
        rifLabel = new javax.swing.JLabel();
        jLabel58 = new javax.swing.JLabel();
        nombreClienteLabel = new javax.swing.JLabel();
        jLabel59 = new javax.swing.JLabel();
        ciLabel = new javax.swing.JLabel();
        jLabel63 = new javax.swing.JLabel();
        direccionCliente = new javax.swing.JLabel();
        jLabel65 = new javax.swing.JLabel();
        telefonoCliente = new javax.swing.JLabel();
        mostrarFacturas = new javax.swing.JButton();
        jLabel12 = new javax.swing.JLabel();
        pagoTotalLabel = new javax.swing.JLabel();
        jLabel14 = new javax.swing.JLabel();
        nroFacturaLabel = new javax.swing.JLabel();
        jLabel60 = new javax.swing.JLabel();
        subtotal1 = new javax.swing.JLabel();
        iva1 = new javax.swing.JLabel();
        jLabel61 = new javax.swing.JLabel();
        jLabel62 = new javax.swing.JLabel();
        deposito1 = new javax.swing.JLabel();
        jLabel64 = new javax.swing.JLabel();
        jLabel119 = new javax.swing.JLabel();
        jPanel2 = new javax.swing.JPanel();
        jScrollPane3 = new javax.swing.JScrollPane();
        tablaFactura = new javax.swing.JTable();
        jPanel11 = new javax.swing.JPanel();
        jScrollPane8 = new javax.swing.JScrollPane();
        tablaEmpleadosContratados = new javax.swing.JTable();
        jPanel1 = new javax.swing.JPanel();
        jPanel6 = new javax.swing.JPanel();
        jScrollPane1 = new javax.swing.JScrollPane();
        tablaProveedores = new javax.swing.JTable();
        mostrarProveedores = new javax.swing.JButton();
        jPanel8 = new javax.swing.JPanel();
        jLabel2 = new javax.swing.JLabel();
        nombre = new javax.swing.JTextField();
        jLabel6 = new javax.swing.JLabel();
        jLabel16 = new javax.swing.JLabel();
        limpiar = new javax.swing.JButton();
        insertarProveedor = new javax.swing.JButton();
        jLabel23 = new javax.swing.JLabel();
        direccion = new javax.swing.JTextField();
        telefono = new javax.swing.JTextField();
        jLabel29 = new javax.swing.JLabel();
        jPanel9 = new javax.swing.JPanel();
        jLabel7 = new javax.swing.JLabel();
        jLabel8 = new javax.swing.JLabel();
        nombreProveedor = new javax.swing.JLabel();
        jLabel10 = new javax.swing.JLabel();
        eliminarProveedor = new javax.swing.JButton();
        jLabel30 = new javax.swing.JLabel();
        jLabel31 = new javax.swing.JLabel();
        telefonoProveedor = new javax.swing.JLabel();
        jScrollPane13 = new javax.swing.JScrollPane();
        direccionProveedor = new javax.swing.JTextArea();
        codigoProveedorEliminar = new javax.swing.JLabel();
        jPanel10 = new javax.swing.JPanel();
        jLabel9 = new javax.swing.JLabel();
        jLabel11 = new javax.swing.JLabel();
        jLabel15 = new javax.swing.JLabel();
        nombre2 = new javax.swing.JTextField();
        checkNombre = new javax.swing.JCheckBox();
        jLabel17 = new javax.swing.JLabel();
        modificarProveedor = new javax.swing.JButton();
        jLabel32 = new javax.swing.JLabel();
        checkDireccion = new javax.swing.JCheckBox();
        jLabel33 = new javax.swing.JLabel();
        nombre4 = new javax.swing.JTextField();
        checkTelefono = new javax.swing.JCheckBox();
        jScrollPane14 = new javax.swing.JScrollPane();
        direccionComp3 = new javax.swing.JTextArea();
        codigoProveedorModificar = new javax.swing.JLabel();
        jPanel4 = new javax.swing.JPanel();
        jPanel19 = new javax.swing.JPanel();
        jLabel37 = new javax.swing.JLabel();
        jcbEventosInsumosASubcontratar = new javax.swing.JComboBox();
        jLabel39 = new javax.swing.JLabel();
        fechaInsumoSubcontrato = new javax.swing.JLabel();
        jLabel40 = new javax.swing.JLabel();
        jLabel44 = new javax.swing.JLabel();
        horaInicioEventosInsumo = new javax.swing.JLabel();
        horaFinEventosInsumo = new javax.swing.JLabel();
        jPanel18 = new javax.swing.JPanel();
        jScrollPane4 = new javax.swing.JScrollPane();
        tablaInsumosASubcontratar = new javax.swing.JTable();
        jPanel20 = new javax.swing.JPanel();
        jScrollPane15 = new javax.swing.JScrollPane();
        tablaProveedor = new javax.swing.JTable();
        mostrarOrdenCompra = new javax.swing.JButton();
        insertarOrdenCompra = new javax.swing.JButton();
        jPanel21 = new javax.swing.JPanel();
        jLabel47 = new javax.swing.JLabel();
        tipoPagoCombo1 = new javax.swing.JComboBox();
        jPanel22 = new javax.swing.JPanel();
        jLabel48 = new javax.swing.JLabel();
        tipoTarjetaCombo1 = new javax.swing.JComboBox();
        jLabel49 = new javax.swing.JLabel();
        jLabel50 = new javax.swing.JLabel();
        jLabel51 = new javax.swing.JLabel();
        nombreBanco1 = new javax.swing.JTextField();
        jLabel52 = new javax.swing.JLabel();
        tipoCtaCombo1 = new javax.swing.JComboBox();
        codigoSeguridad1 = new javax.swing.JTextField();
        numeroTarjeta1 = new javax.swing.JTextField();
        limpiar11 = new javax.swing.JButton();
        jPanel38 = new javax.swing.JPanel();
        jLabel54 = new javax.swing.JLabel();
        jLabel55 = new javax.swing.JLabel();
        numeroCheque1 = new javax.swing.JTextField();
        nombreBancoCheque1 = new javax.swing.JTextField();
        limpiar12 = new javax.swing.JButton();
        jLabel45 = new javax.swing.JLabel();
        totalPagoPorInsumo = new javax.swing.JLabel();
        labelCancelado1 = new javax.swing.JLabel();
        jLabel121 = new javax.swing.JLabel();
        duracionEventoOrden = new javax.swing.JLabel();
        jLabel124 = new javax.swing.JLabel();
        jPanel5 = new javax.swing.JPanel();
        jPanel23 = new javax.swing.JPanel();
        jScrollPane5 = new javax.swing.JScrollPane();
        tablaInsumosSubcontratados = new javax.swing.JTable();
        mostrarReciboPago = new javax.swing.JButton();
        jLabel66 = new javax.swing.JLabel();
        jLabel67 = new javax.swing.JLabel();
        jcbInsumosSubcontratados = new javax.swing.JComboBox();
        jLabel72 = new javax.swing.JLabel();
        jcbProveedoresRecibo = new javax.swing.JComboBox();
        jPanel35 = new javax.swing.JPanel();
        jLabel115 = new javax.swing.JLabel();
        jLabel116 = new javax.swing.JLabel();
        jLabel117 = new javax.swing.JLabel();
        jLabel71 = new javax.swing.JLabel();
        totalPagoPorProveedorRecibo = new javax.swing.JLabel();
        cantidadInsumosProveedor = new javax.swing.JLabel();
        direccionProveedorRecibo = new javax.swing.JLabel();
        telefonoProveedorRecibo = new javax.swing.JLabel();
        jPanel33 = new javax.swing.JPanel();
        jLabel68 = new javax.swing.JLabel();
        fechaInsumoSubcontratados = new javax.swing.JLabel();
        jLabel69 = new javax.swing.JLabel();
        horaInicioEventosInsumoSubcontratado = new javax.swing.JLabel();
        jLabel70 = new javax.swing.JLabel();
        horaFinEventosInsumoSubcontratado = new javax.swing.JLabel();
        jLabel74 = new javax.swing.JLabel();
        labelTotalInsumos = new javax.swing.JLabel();
        totalSubcontratadoRecibo = new javax.swing.JLabel();
        jLabel73 = new javax.swing.JLabel();
        jPanel12 = new javax.swing.JPanel();
        jPanel13 = new javax.swing.JPanel();
        jLabel75 = new javax.swing.JLabel();
        idEventosCuadre = new javax.swing.JComboBox();
        mostrarCuadreGanancia = new javax.swing.JButton();
        jPanel24 = new javax.swing.JPanel();
        jLabel76 = new javax.swing.JLabel();
        jLabel77 = new javax.swing.JLabel();
        fechaEventoCuadre = new javax.swing.JLabel();
        ejecutivoEncargadoCuadre = new javax.swing.JLabel();
        jLabel78 = new javax.swing.JLabel();
        horaInicioCuadre = new javax.swing.JLabel();
        jLabel79 = new javax.swing.JLabel();
        horaFinCuadre = new javax.swing.JLabel();
        jPanel29 = new javax.swing.JPanel();
        jLabel89 = new javax.swing.JLabel();
        nombreClienteCuadre = new javax.swing.JLabel();
        telefonoCuadre = new javax.swing.JLabel();
        jLabel90 = new javax.swing.JLabel();
        rifCuadre = new javax.swing.JLabel();
        jLabel91 = new javax.swing.JLabel();
        ciCuadre = new javax.swing.JLabel();
        jLabel92 = new javax.swing.JLabel();
        jPanel25 = new javax.swing.JPanel();
        jLabel94 = new javax.swing.JLabel();
        montoTotalPerdido = new javax.swing.JLabel();
        jLabel93 = new javax.swing.JLabel();
        montoTotalGanado = new javax.swing.JLabel();
        jLabel106 = new javax.swing.JLabel();
        labelGanadoPerdido = new javax.swing.JLabel();
        jLabel107 = new javax.swing.JLabel();
        jLabel108 = new javax.swing.JLabel();
        jLabel85 = new javax.swing.JLabel();
        jLabel113 = new javax.swing.JLabel();
        gastoContratados = new javax.swing.JLabel();
        jPanel26 = new javax.swing.JPanel();
        jScrollPane6 = new javax.swing.JScrollPane();
        tablaFacturaCuadre = new javax.swing.JTable();
        jLabel82 = new javax.swing.JLabel();
        jLabel86 = new javax.swing.JLabel();
        jLabel87 = new javax.swing.JLabel();
        jLabel88 = new javax.swing.JLabel();
        pagoTotalLabelCuadre = new javax.swing.JLabel();
        depositoCuadre = new javax.swing.JLabel();
        ivaCuadre = new javax.swing.JLabel();
        subtotalCuadre = new javax.swing.JLabel();
        jLabel80 = new javax.swing.JLabel();
        totalInsumoFacturado = new javax.swing.JLabel();
        jPanel28 = new javax.swing.JPanel();
        jScrollPane7 = new javax.swing.JScrollPane();
        tablaInsumosSubcontratadosCuadre = new javax.swing.JTable();
        jLabel84 = new javax.swing.JLabel();
        jcbProveedoresCuadre = new javax.swing.JComboBox();
        jLabel83 = new javax.swing.JLabel();
        totalPagoPorProveedorCuadre = new javax.swing.JLabel();
        jLabel81 = new javax.swing.JLabel();
        totalInsumoSubcontratado = new javax.swing.JLabel();
        jPanel27 = new javax.swing.JPanel();
        jPanel34 = new javax.swing.JPanel();
        consultarEstadistica = new javax.swing.JButton();
        jPanel31 = new javax.swing.JPanel();
        jLabel99 = new javax.swing.JLabel();
        horaInicioEstadistica = new javax.swing.JLabel();
        jLabel100 = new javax.swing.JLabel();
        nombreClienteEstadistica = new javax.swing.JLabel();
        jLabel101 = new javax.swing.JLabel();
        ciEstadistica = new javax.swing.JLabel();
        jLabel103 = new javax.swing.JLabel();
        telefonoEstadistica = new javax.swing.JLabel();
        jLabel96 = new javax.swing.JLabel();
        ejecutivoEncargadoEstadistica = new javax.swing.JLabel();
        jLabel127 = new javax.swing.JLabel();
        jLabel98 = new javax.swing.JLabel();
        horaFinEstadistica = new javax.swing.JLabel();
        jLabel129 = new javax.swing.JLabel();
        fechaEventoEstadistica = new javax.swing.JLabel();
        jLabel104 = new javax.swing.JLabel();
        jPanel32 = new javax.swing.JPanel();
        jScrollPane12 = new javax.swing.JScrollPane();
        tablaEstadisticas = new javax.swing.JTable();
        jPanel30 = new javax.swing.JPanel();
        jLabel95 = new javax.swing.JLabel();
        jLabel97 = new javax.swing.JLabel();
        jLabel102 = new javax.swing.JLabel();
        jLabel105 = new javax.swing.JLabel();
        montoCotizadoPorMes = new javax.swing.JLabel();
        montoSubcontratadoPorMes = new javax.swing.JLabel();
        gananciasPorMes = new javax.swing.JLabel();
        perdidasPorMes = new javax.swing.JLabel();
        jLabel125 = new javax.swing.JLabel();
        gastoNomina = new javax.swing.JLabel();
        jLabel126 = new javax.swing.JLabel();
        jLabel128 = new javax.swing.JLabel();
        otrosGastos = new javax.swing.JLabel();
        monthChooser = new com.toedter.calendar.JMonthChooser();
        jLabel109 = new javax.swing.JLabel();
        jLabel110 = new javax.swing.JLabel();
        jLabel111 = new javax.swing.JLabel();
        jLabel112 = new javax.swing.JLabel();
        cantidadEventosMes = new javax.swing.JLabel();
        salir = new javax.swing.JButton();
        jMenuBar1 = new javax.swing.JMenuBar();
        archivo = new javax.swing.JMenu();
        nuevaCotizacion = new javax.swing.JMenuItem();
        informacionSistema = new javax.swing.JMenuItem();
        jMenuItem2 = new javax.swing.JMenuItem();
        jSeparator1 = new javax.swing.JSeparator();
        exit = new javax.swing.JMenuItem();
        jMenu1 = new javax.swing.JMenu();
        acercaDe = new javax.swing.JMenuItem();

        setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);
        setTitle("Informacion del sistema");
        setMinimumSize(new java.awt.Dimension(866, 753));
        setResizable(false);

        jTabbedPane1.setMaximumSize(new java.awt.Dimension(866, 753));
        jTabbedPane1.setPreferredSize(new java.awt.Dimension(866, 753));

        jPanel15.setBorder(javax.swing.BorderFactory.createTitledBorder(""));
        jPanel15.setFont(new java.awt.Font("Microsoft Sans Serif", 0, 12));
        jPanel15.setPreferredSize(new java.awt.Dimension(810, 283));

        idEventosSegundaCuota.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                idEventosSegundaCuotaActionPerformed(evt);
            }
        });

        jLabel53.setFont(new java.awt.Font("Tahoma", 1, 11));
        jLabel53.setText("SELECCIONE EL EVENTO:");

        jLabel1.setFont(new java.awt.Font("Calibri", 0, 12));
        jLabel1.setIcon(new javax.swing.ImageIcon(getClass().getResource("/Iconos/logoPeq1.PNG"))); // NOI18N

        jLabel3.setFont(new java.awt.Font("Script MT Bold", 2, 18));
        jLabel3.setText("Festejos y Decoraciones MDJ");

        jLabel5.setFont(new java.awt.Font("Tahoma", 1, 11));
        jLabel5.setText("Fecha:");

        fechaCotizacionLabel.setText("----/--/--");

        jPanel16.setBorder(javax.swing.BorderFactory.createTitledBorder(null, "Información del Evento", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Tahoma", 1, 11))); // NOI18N

        jLabel56.setText("Fecha del Evento:");

        jLabel4.setText("Ejecutivo Encargado:");

        fechaLabel.setText("----/--/--");

        ejecutivoEncargadoLabel.setText("Ejecutivo Encargado");

        jLabel34.setText("Hora del Evento:");

        horaInicio.setText("00:00");

        jLabel36.setText("a");

        horaFin.setText("00:00");

        jLabel20.setText("Duración:");

        duracionEvento.setText("0");

        jLabel122.setText("hora(s)");

        jLabel13.setText("Lugar del Evento:");

        lugarEvento.setText("lugar evento");

        org.jdesktop.layout.GroupLayout jPanel16Layout = new org.jdesktop.layout.GroupLayout(jPanel16);
        jPanel16.setLayout(jPanel16Layout);
        jPanel16Layout.setHorizontalGroup(
            jPanel16Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel16Layout.createSequentialGroup()
                .addContainerGap()
                .add(jPanel16Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(jPanel16Layout.createSequentialGroup()
                        .add(jLabel56)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(fechaLabel))
                    .add(jPanel16Layout.createSequentialGroup()
                        .add(jLabel34)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(horaInicio)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(jLabel36)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(horaFin))
                    .add(jPanel16Layout.createSequentialGroup()
                        .add(jLabel20)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(duracionEvento)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(jLabel122))
                    .add(jPanel16Layout.createSequentialGroup()
                        .add(jLabel13)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(lugarEvento))
                    .add(jPanel16Layout.createSequentialGroup()
                        .add(jLabel4)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(ejecutivoEncargadoLabel)))
                .addContainerGap(org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );
        jPanel16Layout.setVerticalGroup(
            jPanel16Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(org.jdesktop.layout.GroupLayout.TRAILING, jPanel16Layout.createSequentialGroup()
                .add(jPanel16Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(jLabel56)
                    .add(fechaLabel))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                .add(jPanel16Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(jLabel34)
                    .add(jLabel36)
                    .add(horaFin)
                    .add(horaInicio))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                .add(jPanel16Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(jLabel20)
                    .add(duracionEvento)
                    .add(jLabel122))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                .add(jPanel16Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(jLabel13)
                    .add(lugarEvento))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED, 25, Short.MAX_VALUE)
                .add(jPanel16Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(jLabel4)
                    .add(ejecutivoEncargadoLabel))
                .addContainerGap())
        );

        jPanel16Layout.linkSize(new java.awt.Component[] {duracionEvento, ejecutivoEncargadoLabel, fechaLabel, horaFin, horaInicio, jLabel122, jLabel13, jLabel20, jLabel34, jLabel36, jLabel4, jLabel56, lugarEvento}, org.jdesktop.layout.GroupLayout.VERTICAL);

        jPanel17.setBorder(javax.swing.BorderFactory.createTitledBorder(null, "Información del Cliente", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Tahoma", 1, 11))); // NOI18N

        jLabel57.setText("RIF:");

        rifLabel.setText("--");

        jLabel58.setText("Nombre del Cliente:");

        nombreClienteLabel.setText("Nombre Cliente");

        jLabel59.setText("C.I.:");

        ciLabel.setText("--");

        jLabel63.setText("Dirección:");

        direccionCliente.setText("Dirección");

        jLabel65.setText("Teléfono:");

        telefonoCliente.setText("teléfono");

        org.jdesktop.layout.GroupLayout jPanel17Layout = new org.jdesktop.layout.GroupLayout(jPanel17);
        jPanel17.setLayout(jPanel17Layout);
        jPanel17Layout.setHorizontalGroup(
            jPanel17Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel17Layout.createSequentialGroup()
                .addContainerGap()
                .add(jPanel17Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(jPanel17Layout.createSequentialGroup()
                        .add(jLabel58)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(nombreClienteLabel))
                    .add(jPanel17Layout.createSequentialGroup()
                        .add(jLabel59)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(ciLabel))
                    .add(jPanel17Layout.createSequentialGroup()
                        .add(jLabel57)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(rifLabel))
                    .add(jPanel17Layout.createSequentialGroup()
                        .add(jLabel63)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(direccionCliente))
                    .add(jPanel17Layout.createSequentialGroup()
                        .add(jLabel65)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(telefonoCliente)))
                .addContainerGap(358, Short.MAX_VALUE))
        );
        jPanel17Layout.setVerticalGroup(
            jPanel17Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel17Layout.createSequentialGroup()
                .add(jPanel17Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(nombreClienteLabel)
                    .add(jLabel58))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                .add(jPanel17Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(jLabel59)
                    .add(ciLabel))
                .add(14, 14, 14)
                .add(jPanel17Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING)
                    .add(rifLabel)
                    .add(jLabel57))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                .add(jPanel17Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(jLabel63)
                    .add(direccionCliente))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED, 12, Short.MAX_VALUE)
                .add(jPanel17Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(jLabel65)
                    .add(telefonoCliente))
                .add(22, 22, 22))
        );

        mostrarFacturas.setIcon(new javax.swing.ImageIcon(getClass().getResource("/Iconos/search.png"))); // NOI18N

        org.jdesktop.beansbinding.Binding binding = org.jdesktop.beansbinding.Bindings.createAutoBinding(org.jdesktop.beansbinding.AutoBinding.UpdateStrategy.READ_WRITE, mostrarFacturas, org.jdesktop.beansbinding.ELProperty.create("Haga click en el botón para generar las facturas de aquellos eventos que ya pagaron la segunda cuota"), mostrarFacturas, org.jdesktop.beansbinding.BeanProperty.create("toolTipText"));
        bindingGroup.addBinding(binding);

        mostrarFacturas.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                mostrarFacturasActionPerformed(evt);
            }
        });

        jLabel12.setFont(new java.awt.Font("Tahoma", 1, 11));
        jLabel12.setText("TOTAL Bs.F.:");

        pagoTotalLabel.setFont(new java.awt.Font("Tahoma", 1, 14));
        pagoTotalLabel.setForeground(new java.awt.Color(0, 153, 0));
        pagoTotalLabel.setText("0.0");

        jLabel14.setText("Nro.");

        nroFacturaLabel.setForeground(new java.awt.Color(204, 0, 0));
        nroFacturaLabel.setText("000000");

        jLabel60.setFont(new java.awt.Font("Tahoma", 0, 10));
        jLabel60.setText("Sub - TOTAL BsF.");

        subtotal1.setFont(new java.awt.Font("Tahoma", 0, 10));
        subtotal1.setHorizontalAlignment(javax.swing.SwingConstants.RIGHT);
        subtotal1.setText("0.0");
        subtotal1.setHorizontalTextPosition(javax.swing.SwingConstants.RIGHT);

        iva1.setFont(new java.awt.Font("Tahoma", 0, 10));
        iva1.setHorizontalAlignment(javax.swing.SwingConstants.RIGHT);
        iva1.setText("0.0");

        jLabel61.setFont(new java.awt.Font("Tahoma", 0, 10));
        jLabel61.setText("IVA 9% BsF.");

        jLabel62.setFont(new java.awt.Font("Tahoma", 0, 10));
        jLabel62.setText("5% Deposito por Averias BsF.");

        deposito1.setFont(new java.awt.Font("Tahoma", 0, 10));
        deposito1.setHorizontalAlignment(javax.swing.SwingConstants.RIGHT);
        deposito1.setText("0.0");

        jLabel64.setText("00 -");

        jLabel119.setFont(new java.awt.Font("Script MT Bold", 2, 18));
        jLabel119.setText("Facturas de");

        jPanel2.setBorder(javax.swing.BorderFactory.createTitledBorder("Insumos"));

        tablaFactura.setModel(new javax.swing.table.DefaultTableModel(
            new Object [][] {

            },
            new String [] {
                "Cantidad", "Concepto", "Costo Unitario", "Monto"
            }
        ) {
            boolean[] canEdit = new boolean [] {
                false, false, false, false
            };

            public boolean isCellEditable(int rowIndex, int columnIndex) {
                return canEdit [columnIndex];
            }
        });
        tablaFactura.getTableHeader().setReorderingAllowed(false);
        jScrollPane3.setViewportView(tablaFactura);

        org.jdesktop.layout.GroupLayout jPanel2Layout = new org.jdesktop.layout.GroupLayout(jPanel2);
        jPanel2.setLayout(jPanel2Layout);
        jPanel2Layout.setHorizontalGroup(
            jPanel2Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel2Layout.createSequentialGroup()
                .addContainerGap()
                .add(jScrollPane3, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 380, Short.MAX_VALUE)
                .addContainerGap())
        );
        jPanel2Layout.setVerticalGroup(
            jPanel2Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel2Layout.createSequentialGroup()
                .add(jScrollPane3, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 154, Short.MAX_VALUE)
                .addContainerGap())
        );

        jPanel11.setBorder(javax.swing.BorderFactory.createTitledBorder("Personas Contratadas"));

        tablaEmpleadosContratados.setModel(new javax.swing.table.DefaultTableModel(
            new Object [][] {

            },
            new String [] {
                "Cedula", "Nombre", "Cargo", "CostoHora"
            }
        ) {
            boolean[] canEdit = new boolean [] {
                false, false, false, false
            };

            public boolean isCellEditable(int rowIndex, int columnIndex) {
                return canEdit [columnIndex];
            }
        });
        tablaEmpleadosContratados.getTableHeader().setReorderingAllowed(false);
        jScrollPane8.setViewportView(tablaEmpleadosContratados);

        org.jdesktop.layout.GroupLayout jPanel11Layout = new org.jdesktop.layout.GroupLayout(jPanel11);
        jPanel11.setLayout(jPanel11Layout);
        jPanel11Layout.setHorizontalGroup(
            jPanel11Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel11Layout.createSequentialGroup()
                .addContainerGap()
                .add(jScrollPane8, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 347, Short.MAX_VALUE)
                .addContainerGap())
        );
        jPanel11Layout.setVerticalGroup(
            jPanel11Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel11Layout.createSequentialGroup()
                .add(jScrollPane8, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 154, Short.MAX_VALUE)
                .addContainerGap())
        );

        org.jdesktop.layout.GroupLayout jPanel15Layout = new org.jdesktop.layout.GroupLayout(jPanel15);
        jPanel15.setLayout(jPanel15Layout);
        jPanel15Layout.setHorizontalGroup(
            jPanel15Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel15Layout.createSequentialGroup()
                .addContainerGap()
                .add(jPanel15Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(jPanel15Layout.createSequentialGroup()
                        .add(jLabel1)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(jPanel15Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                            .add(jLabel119, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 253, Short.MAX_VALUE)
                            .add(jLabel3, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 231, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(jPanel15Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                            .add(jLabel53)
                            .add(jPanel15Layout.createSequentialGroup()
                                .add(idEventosSegundaCuota, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 215, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                                .add(mostrarFacturas)
                                .add(103, 103, 103)
                                .add(jPanel15Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING)
                                    .add(jPanel15Layout.createSequentialGroup()
                                        .add(jLabel5)
                                        .add(34, 34, 34)
                                        .add(fechaCotizacionLabel))
                                    .add(jPanel15Layout.createSequentialGroup()
                                        .add(jLabel14)
                                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                                        .add(jLabel64)
                                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                                        .add(nroFacturaLabel))))))
                    .add(org.jdesktop.layout.GroupLayout.TRAILING, jPanel15Layout.createSequentialGroup()
                        .add(jPanel15Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING)
                            .add(jLabel12)
                            .add(jLabel60)
                            .add(jLabel61)
                            .add(jLabel62))
                        .add(18, 18, 18)
                        .add(jPanel15Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                            .add(org.jdesktop.layout.GroupLayout.TRAILING, deposito1)
                            .add(org.jdesktop.layout.GroupLayout.TRAILING, iva1)
                            .add(org.jdesktop.layout.GroupLayout.TRAILING, subtotal1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 82, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                            .add(org.jdesktop.layout.GroupLayout.TRAILING, pagoTotalLabel)))
                    .add(org.jdesktop.layout.GroupLayout.TRAILING, jPanel15Layout.createSequentialGroup()
                        .add(jPanel16, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(jPanel17, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                    .add(jPanel15Layout.createSequentialGroup()
                        .add(jPanel11, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(jPanel2, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)))
                .addContainerGap())
        );

        jPanel15Layout.linkSize(new java.awt.Component[] {deposito1, iva1, subtotal1}, org.jdesktop.layout.GroupLayout.HORIZONTAL);

        jPanel15Layout.setVerticalGroup(
            jPanel15Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel15Layout.createSequentialGroup()
                .add(jPanel15Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(jPanel15Layout.createSequentialGroup()
                        .addContainerGap()
                        .add(jPanel15Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                            .add(jLabel14)
                            .add(jLabel64)
                            .add(nroFacturaLabel))
                        .add(41, 41, 41)
                        .add(jPanel15Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                            .add(jLabel5)
                            .add(fechaCotizacionLabel)))
                    .add(jPanel15Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING)
                        .add(jPanel15Layout.createSequentialGroup()
                            .add(jLabel119)
                            .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                            .add(jLabel3))
                        .add(jLabel1))
                    .add(jPanel15Layout.createSequentialGroup()
                        .addContainerGap(35, Short.MAX_VALUE)
                        .add(jPanel15Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING)
                            .add(jPanel15Layout.createSequentialGroup()
                                .add(jLabel53)
                                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                                .add(idEventosSegundaCuota, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
                            .add(mostrarFacturas, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 23, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
                        .add(18, 18, 18)))
                .add(15, 15, 15)
                .add(jPanel15Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(jPanel15Layout.createSequentialGroup()
                        .add(jPanel16, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                        .add(5, 5, 5))
                    .add(jPanel15Layout.createSequentialGroup()
                        .add(jPanel17, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)))
                .add(jPanel15Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING)
                    .add(jPanel11, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .add(jPanel2, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                .add(jPanel15Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(jPanel15Layout.createSequentialGroup()
                        .add(subtotal1)
                        .add(5, 5, 5)
                        .add(iva1)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(deposito1)
                        .add(18, 18, 18)
                        .add(pagoTotalLabel))
                    .add(jPanel15Layout.createSequentialGroup()
                        .add(jLabel60)
                        .add(5, 5, 5)
                        .add(jLabel61)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(jLabel62)
                        .add(18, 18, 18)
                        .add(jLabel12)))
                .addContainerGap())
        );

        jPanel15Layout.linkSize(new java.awt.Component[] {deposito1, iva1, subtotal1}, org.jdesktop.layout.GroupLayout.VERTICAL);

        org.jdesktop.layout.GroupLayout jPanel3Layout = new org.jdesktop.layout.GroupLayout(jPanel3);
        jPanel3.setLayout(jPanel3Layout);
        jPanel3Layout.setHorizontalGroup(
            jPanel3Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel3Layout.createSequentialGroup()
                .addContainerGap()
                .add(jPanel15, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 841, Short.MAX_VALUE)
                .addContainerGap())
        );
        jPanel3Layout.setVerticalGroup(
            jPanel3Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel3Layout.createSequentialGroup()
                .addContainerGap()
                .add(jPanel15, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 595, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                .addContainerGap(18, Short.MAX_VALUE))
        );

        jTabbedPane1.addTab("Facturas", jPanel3);

        jPanel6.setBorder(javax.swing.BorderFactory.createTitledBorder(""));
        jPanel6.setFont(new java.awt.Font("Microsoft Sans Serif", 0, 12));

        tablaProveedores.setModel(new javax.swing.table.DefaultTableModel(
            new Object [][] {

            },
            new String [] {
                "Código", "Nombre", "Dirección", "Teléfono"
            }
        ) {
            boolean[] canEdit = new boolean [] {
                false, false, false, false
            };

            public boolean isCellEditable(int rowIndex, int columnIndex) {
                return canEdit [columnIndex];
            }
        });
        tablaProveedores.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                tablaProveedoresMouseClicked(evt);
            }
        });
        jScrollPane1.setViewportView(tablaProveedores);

        mostrarProveedores.setIcon(new javax.swing.ImageIcon(getClass().getResource("/Iconos/search.png"))); // NOI18N
        mostrarProveedores.setText("Consultar");

        binding = org.jdesktop.beansbinding.Bindings.createAutoBinding(org.jdesktop.beansbinding.AutoBinding.UpdateStrategy.READ_WRITE, mostrarProveedores, org.jdesktop.beansbinding.ELProperty.create("Haga click en el botón para mostrar los proveedores"), mostrarProveedores, org.jdesktop.beansbinding.BeanProperty.create("toolTipText"));
        bindingGroup.addBinding(binding);

        mostrarProveedores.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                mostrarProveedoresActionPerformed(evt);
            }
        });

        org.jdesktop.layout.GroupLayout jPanel6Layout = new org.jdesktop.layout.GroupLayout(jPanel6);
        jPanel6.setLayout(jPanel6Layout);
        jPanel6Layout.setHorizontalGroup(
            jPanel6Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 825, Short.MAX_VALUE)
            .add(org.jdesktop.layout.GroupLayout.TRAILING, jPanel6Layout.createSequentialGroup()
                .addContainerGap()
                .add(mostrarProveedores))
        );
        jPanel6Layout.setVerticalGroup(
            jPanel6Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(org.jdesktop.layout.GroupLayout.TRAILING, jPanel6Layout.createSequentialGroup()
                .addContainerGap()
                .add(jScrollPane1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 199, Short.MAX_VALUE)
                .add(18, 18, 18)
                .add(mostrarProveedores)
                .addContainerGap())
        );

        jPanel8.setBorder(javax.swing.BorderFactory.createTitledBorder("Insertar Proveedor"));
        jPanel8.setFont(new java.awt.Font("Microsoft Sans Serif", 0, 12));

        jLabel2.setText("(*) Nombre:");

        nombre.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                nombreActionPerformed(evt);
            }
        });

        jLabel6.setIcon(new javax.swing.ImageIcon(getClass().getResource("/Iconos/edit_add.png"))); // NOI18N

        jLabel16.setFont(new java.awt.Font("Tahoma", 0, 10));
        jLabel16.setForeground(new java.awt.Color(255, 0, 0));
        jLabel16.setText("Campos obligatorios (*)");

        limpiar.setText("Limpiar");
        limpiar.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                limpiarActionPerformed(evt);
            }
        });

        insertarProveedor.setText("Insertar");
        insertarProveedor.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                insertarProveedorActionPerformed(evt);
            }
        });

        jLabel23.setText("(*) Dirección:");

        direccion.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                direccionActionPerformed(evt);
            }
        });

        telefono.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                telefonoActionPerformed(evt);
            }
        });

        jLabel29.setText("(*) Teléfono:");

        org.jdesktop.layout.GroupLayout jPanel8Layout = new org.jdesktop.layout.GroupLayout(jPanel8);
        jPanel8.setLayout(jPanel8Layout);
        jPanel8Layout.setHorizontalGroup(
            jPanel8Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel8Layout.createSequentialGroup()
                .add(19, 19, 19)
                .add(jPanel8Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(jPanel8Layout.createSequentialGroup()
                        .add(jLabel2)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(nombre, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 147, Short.MAX_VALUE))
                    .add(jPanel8Layout.createSequentialGroup()
                        .add(jLabel23)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(direccion, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 147, Short.MAX_VALUE))
                    .add(jPanel8Layout.createSequentialGroup()
                        .add(jLabel29)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(telefono, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 147, Short.MAX_VALUE)))
                .addContainerGap())
            .add(org.jdesktop.layout.GroupLayout.TRAILING, jPanel8Layout.createSequentialGroup()
                .addContainerGap(86, Short.MAX_VALUE)
                .add(limpiar)
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                .add(insertarProveedor)
                .add(10, 10, 10))
            .add(jPanel8Layout.createSequentialGroup()
                .add(jLabel6)
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                .add(jLabel16)
                .addContainerGap(108, Short.MAX_VALUE))
        );

        jPanel8Layout.linkSize(new java.awt.Component[] {direccion, nombre, telefono}, org.jdesktop.layout.GroupLayout.HORIZONTAL);

        jPanel8Layout.linkSize(new java.awt.Component[] {insertarProveedor, limpiar}, org.jdesktop.layout.GroupLayout.HORIZONTAL);

        jPanel8Layout.linkSize(new java.awt.Component[] {jLabel2, jLabel23, jLabel29}, org.jdesktop.layout.GroupLayout.HORIZONTAL);

        jPanel8Layout.setVerticalGroup(
            jPanel8Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel8Layout.createSequentialGroup()
                .add(jPanel8Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(jLabel6)
                    .add(jLabel16))
                .add(18, 18, 18)
                .add(jPanel8Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(jLabel2)
                    .add(nombre, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                .add(jPanel8Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(jLabel23)
                    .add(direccion, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                .add(jPanel8Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(jLabel29)
                    .add(telefono, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED, 127, Short.MAX_VALUE)
                .add(jPanel8Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(limpiar)
                    .add(insertarProveedor))
                .addContainerGap())
        );

        jPanel9.setBorder(javax.swing.BorderFactory.createTitledBorder("Eliminar Proveedor"));

        jLabel7.setIcon(new javax.swing.ImageIcon(getClass().getResource("/Iconos/edit_remove.png"))); // NOI18N

        jLabel8.setText("Código:");

        nombreProveedor.setText("nombre proveedor");

        jLabel10.setText("Nombre:");

        eliminarProveedor.setText("Eliminar");
        eliminarProveedor.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                eliminarProveedorActionPerformed(evt);
            }
        });

        jLabel30.setText("Dirección:");

        jLabel31.setText("Teléfono:");

        telefonoProveedor.setText("telefono");

        direccionProveedor.setColumns(20);
        direccionProveedor.setEditable(false);
        direccionProveedor.setFont(new java.awt.Font("Tahoma", 0, 11));
        direccionProveedor.setRows(5);
        jScrollPane13.setViewportView(direccionProveedor);

        codigoProveedorEliminar.setText("codigo");

        org.jdesktop.layout.GroupLayout jPanel9Layout = new org.jdesktop.layout.GroupLayout(jPanel9);
        jPanel9.setLayout(jPanel9Layout);
        jPanel9Layout.setHorizontalGroup(
            jPanel9Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel9Layout.createSequentialGroup()
                .addContainerGap()
                .add(jPanel9Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(jPanel9Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                        .add(jPanel9Layout.createSequentialGroup()
                            .add(jPanel9Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                                .add(jLabel7)
                                .add(jPanel9Layout.createSequentialGroup()
                                    .add(jPanel9Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                                        .add(jLabel30)
                                        .add(jLabel10)
                                        .add(jLabel8))
                                    .add(jPanel9Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                                        .add(jPanel9Layout.createSequentialGroup()
                                            .add(6, 6, 6)
                                            .add(jPanel9Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING)
                                                .add(jScrollPane13, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 147, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                                                .add(org.jdesktop.layout.GroupLayout.LEADING, jPanel9Layout.createSequentialGroup()
                                                    .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                                                    .add(nombreProveedor, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 147, Short.MAX_VALUE))))
                                        .add(jPanel9Layout.createSequentialGroup()
                                            .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                                            .add(codigoProveedorEliminar, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 143, Short.MAX_VALUE)))))
                            .add(35, 35, 35))
                        .add(jPanel9Layout.createSequentialGroup()
                            .add(jLabel31)
                            .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                            .add(telefonoProveedor)
                            .addContainerGap(143, Short.MAX_VALUE)))
                    .add(org.jdesktop.layout.GroupLayout.TRAILING, jPanel9Layout.createSequentialGroup()
                        .add(eliminarProveedor)
                        .addContainerGap())))
        );

        jPanel9Layout.linkSize(new java.awt.Component[] {jLabel10, jLabel8}, org.jdesktop.layout.GroupLayout.HORIZONTAL);

        jPanel9Layout.setVerticalGroup(
            jPanel9Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel9Layout.createSequentialGroup()
                .add(jLabel7)
                .add(21, 21, 21)
                .add(jPanel9Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(jLabel8)
                    .add(codigoProveedorEliminar))
                .add(11, 11, 11)
                .add(jPanel9Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(jLabel10)
                    .add(nombreProveedor))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                .add(jPanel9Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(jLabel30)
                    .add(jScrollPane13, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 86, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                .add(jPanel9Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(telefonoProveedor)
                    .add(jLabel31))
                .add(40, 40, 40)
                .add(eliminarProveedor)
                .addContainerGap())
        );

        jPanel9Layout.linkSize(new java.awt.Component[] {jLabel10, jLabel8}, org.jdesktop.layout.GroupLayout.VERTICAL);

        jPanel10.setBorder(javax.swing.BorderFactory.createTitledBorder("Modificar Proveedor"));

        jLabel9.setText("Código:");

        jLabel11.setText("Nombre:");

        jLabel15.setIcon(new javax.swing.ImageIcon(getClass().getResource("/Iconos/configure.png"))); // NOI18N

        nombre2.setEnabled(false);
        nombre2.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                nombre2ActionPerformed(evt);
            }
        });

        checkNombre.setFont(new java.awt.Font("Microsoft Sans Serif", 0, 12));
        checkNombre.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                checkNombreActionPerformed(evt);
            }
        });

        jLabel17.setFont(new java.awt.Font("Tahoma", 0, 10));
        jLabel17.setText("Seleccione los campos que desea modificar");

        modificarProveedor.setText("Modificar");
        modificarProveedor.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                modificarProveedorActionPerformed(evt);
            }
        });

        jLabel32.setText("Dirección:");

        checkDireccion.setFont(new java.awt.Font("Microsoft Sans Serif", 0, 12));
        checkDireccion.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                checkDireccionActionPerformed(evt);
            }
        });

        jLabel33.setText("Teléfono:");

        nombre4.setEnabled(false);
        nombre4.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                nombre4ActionPerformed(evt);
            }
        });

        checkTelefono.setFont(new java.awt.Font("Microsoft Sans Serif", 0, 12));
        checkTelefono.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                checkTelefonoActionPerformed(evt);
            }
        });

        direccionComp3.setColumns(20);
        direccionComp3.setFont(new java.awt.Font("Tahoma", 0, 11));
        direccionComp3.setRows(5);
        jScrollPane14.setViewportView(direccionComp3);

        codigoProveedorModificar.setText("codigo");

        org.jdesktop.layout.GroupLayout jPanel10Layout = new org.jdesktop.layout.GroupLayout(jPanel10);
        jPanel10.setLayout(jPanel10Layout);
        jPanel10Layout.setHorizontalGroup(
            jPanel10Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel10Layout.createSequentialGroup()
                .addContainerGap()
                .add(jPanel10Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(jPanel10Layout.createSequentialGroup()
                        .add(jLabel15)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(jLabel17))
                    .add(jPanel10Layout.createSequentialGroup()
                        .add(jPanel10Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING)
                            .add(org.jdesktop.layout.GroupLayout.LEADING, jPanel10Layout.createSequentialGroup()
                                .add(jLabel11)
                                .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                                .add(nombre2, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 157, Short.MAX_VALUE))
                            .add(org.jdesktop.layout.GroupLayout.LEADING, jPanel10Layout.createSequentialGroup()
                                .add(jLabel9)
                                .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                                .add(codigoProveedorModificar, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 157, Short.MAX_VALUE))
                            .add(org.jdesktop.layout.GroupLayout.LEADING, jPanel10Layout.createSequentialGroup()
                                .add(jLabel32)
                                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                                .add(jScrollPane14, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 157, Short.MAX_VALUE)))
                        .add(jPanel10Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                            .add(jPanel10Layout.createSequentialGroup()
                                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                                .add(checkDireccion))
                            .add(org.jdesktop.layout.GroupLayout.TRAILING, jPanel10Layout.createSequentialGroup()
                                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                                .add(checkNombre))))
                    .add(org.jdesktop.layout.GroupLayout.TRAILING, jPanel10Layout.createSequentialGroup()
                        .add(jLabel33)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(nombre4, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 158, Short.MAX_VALUE)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(checkTelefono))
                    .add(org.jdesktop.layout.GroupLayout.TRAILING, modificarProveedor))
                .addContainerGap())
        );

        jPanel10Layout.linkSize(new java.awt.Component[] {jLabel11, jLabel9}, org.jdesktop.layout.GroupLayout.HORIZONTAL);

        jPanel10Layout.setVerticalGroup(
            jPanel10Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel10Layout.createSequentialGroup()
                .add(jPanel10Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(jLabel15)
                    .add(jLabel17))
                .add(19, 19, 19)
                .add(jPanel10Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING)
                    .add(jPanel10Layout.createSequentialGroup()
                        .add(jPanel10Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                            .add(jLabel9)
                            .add(codigoProveedorModificar))
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(jPanel10Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                            .add(nombre2, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                            .add(jLabel11)))
                    .add(checkNombre))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                .add(jPanel10Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(checkDireccion)
                    .add(jLabel32)
                    .add(jScrollPane14, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 86, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
                .add(jPanel10Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(jPanel10Layout.createSequentialGroup()
                        .add(6, 6, 6)
                        .add(jPanel10Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                            .add(nombre4, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                            .add(jLabel33)))
                    .add(jPanel10Layout.createSequentialGroup()
                        .add(2, 2, 2)
                        .add(checkTelefono)))
                .add(39, 39, 39)
                .add(modificarProveedor)
                .addContainerGap())
        );

        jPanel10Layout.linkSize(new java.awt.Component[] {checkNombre, nombre2}, org.jdesktop.layout.GroupLayout.VERTICAL);

        jPanel10Layout.linkSize(new java.awt.Component[] {jLabel11, jLabel9}, org.jdesktop.layout.GroupLayout.VERTICAL);

        org.jdesktop.layout.GroupLayout jPanel1Layout = new org.jdesktop.layout.GroupLayout(jPanel1);
        jPanel1.setLayout(jPanel1Layout);
        jPanel1Layout.setHorizontalGroup(
            jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel1Layout.createSequentialGroup()
                .addContainerGap()
                .add(jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(jPanel6, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .add(jPanel1Layout.createSequentialGroup()
                        .add(jPanel8, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(jPanel10, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED, 47, Short.MAX_VALUE)
                        .add(jPanel9, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)))
                .addContainerGap())
        );
        jPanel1Layout.setVerticalGroup(
            jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(org.jdesktop.layout.GroupLayout.TRAILING, jPanel1Layout.createSequentialGroup()
                .addContainerGap()
                .add(jPanel6, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                .add(jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(jPanel10, 0, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .add(jPanel8, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .add(org.jdesktop.layout.GroupLayout.TRAILING, jPanel9, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                .add(30, 30, 30))
        );

        jTabbedPane1.addTab("Proveedores", jPanel1);

        jPanel4.setPreferredSize(new java.awt.Dimension(832, 592));

        jPanel19.setBorder(javax.swing.BorderFactory.createTitledBorder(""));
        jPanel19.setFont(new java.awt.Font("Microsoft Sans Serif", 0, 12));
        jPanel19.setPreferredSize(new java.awt.Dimension(810, 283));

        jLabel37.setFont(new java.awt.Font("Tahoma", 1, 11));
        jLabel37.setText("SELECCIONE EL EVENTO A CONSULTAR:");

        jcbEventosInsumosASubcontratar.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jcbEventosInsumosASubcontratarActionPerformed(evt);
            }
        });

        jLabel39.setText("Fecha del evento:");

        fechaInsumoSubcontrato.setText("----/--/--");

        jLabel40.setText("Hora del evento:");

        jLabel44.setText("a");

        horaInicioEventosInsumo.setText("00:00");

        horaFinEventosInsumo.setText("00:00");

        jPanel18.setBorder(javax.swing.BorderFactory.createTitledBorder(null, "1ro. Seleccione el insumo a subcontratar", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Tahoma", 1, 11))); // NOI18N

        tablaInsumosASubcontratar.setModel(new javax.swing.table.DefaultTableModel(
            new Object [][] {

            },
            new String [] {
                "Código", "Concepto", "Cantidad", "Costo Unitario del Proveedor"
            }
        ) {
            boolean[] canEdit = new boolean [] {
                false, false, false, false
            };

            public boolean isCellEditable(int rowIndex, int columnIndex) {
                return canEdit [columnIndex];
            }
        });
        tablaInsumosASubcontratar.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                tablaInsumosASubcontratarMouseClicked(evt);
            }
        });
        tablaInsumosASubcontratar.addKeyListener(new java.awt.event.KeyAdapter() {
            public void keyPressed(java.awt.event.KeyEvent evt) {
                tablaInsumosASubcontratarKeyPressed(evt);
            }
        });
        jScrollPane4.setViewportView(tablaInsumosASubcontratar);

        org.jdesktop.layout.GroupLayout jPanel18Layout = new org.jdesktop.layout.GroupLayout(jPanel18);
        jPanel18.setLayout(jPanel18Layout);
        jPanel18Layout.setHorizontalGroup(
            jPanel18Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel18Layout.createSequentialGroup()
                .addContainerGap()
                .add(jScrollPane4, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 388, Short.MAX_VALUE)
                .addContainerGap())
        );
        jPanel18Layout.setVerticalGroup(
            jPanel18Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel18Layout.createSequentialGroup()
                .add(jScrollPane4, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 119, Short.MAX_VALUE)
                .addContainerGap())
        );

        jPanel20.setBorder(javax.swing.BorderFactory.createTitledBorder(null, "2do. Eliga el proveedor", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Tahoma", 1, 11))); // NOI18N

        tablaProveedor.setModel(new javax.swing.table.DefaultTableModel(
            new Object [][] {

            },
            new String [] {
                "Código", "Nombre", "Teléfono"
            }
        ) {
            boolean[] canEdit = new boolean [] {
                false, false, false
            };

            public boolean isCellEditable(int rowIndex, int columnIndex) {
                return canEdit [columnIndex];
            }
        });
        tablaProveedor.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                tablaProveedorMouseClicked(evt);
            }
        });
        jScrollPane15.setViewportView(tablaProveedor);

        org.jdesktop.layout.GroupLayout jPanel20Layout = new org.jdesktop.layout.GroupLayout(jPanel20);
        jPanel20.setLayout(jPanel20Layout);
        jPanel20Layout.setHorizontalGroup(
            jPanel20Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(org.jdesktop.layout.GroupLayout.TRAILING, jPanel20Layout.createSequentialGroup()
                .addContainerGap()
                .add(jScrollPane15, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 293, Short.MAX_VALUE)
                .addContainerGap())
        );
        jPanel20Layout.setVerticalGroup(
            jPanel20Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel20Layout.createSequentialGroup()
                .add(jScrollPane15, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 119, Short.MAX_VALUE)
                .addContainerGap())
        );

        mostrarOrdenCompra.setIcon(new javax.swing.ImageIcon(getClass().getResource("/Iconos/search.png"))); // NOI18N

        binding = org.jdesktop.beansbinding.Bindings.createAutoBinding(org.jdesktop.beansbinding.AutoBinding.UpdateStrategy.READ_WRITE, mostrarOrdenCompra, org.jdesktop.beansbinding.ELProperty.create("Haga click en el botón para mostrar los eventos cuyos insumos faltan por subcontratar"), mostrarOrdenCompra, org.jdesktop.beansbinding.BeanProperty.create("toolTipText"));
        bindingGroup.addBinding(binding);

        mostrarOrdenCompra.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                mostrarOrdenCompraActionPerformed(evt);
            }
        });

        insertarOrdenCompra.setIcon(new javax.swing.ImageIcon(getClass().getResource("/Iconos/cashIconChiquitico.PNG"))); // NOI18N
        insertarOrdenCompra.setText("Pagar");

        binding = org.jdesktop.beansbinding.Bindings.createAutoBinding(org.jdesktop.beansbinding.AutoBinding.UpdateStrategy.READ_WRITE, insertarOrdenCompra, org.jdesktop.beansbinding.ELProperty.create("Haga click en el botón para realizar el pago"), insertarOrdenCompra, org.jdesktop.beansbinding.BeanProperty.create("toolTipText"));
        bindingGroup.addBinding(binding);

        insertarOrdenCompra.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                insertarOrdenCompraActionPerformed(evt);
            }
        });

        jPanel21.setBorder(javax.swing.BorderFactory.createTitledBorder(null, "3ro. Forma de Pago", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Tahoma", 1, 11))); // NOI18N

        jLabel47.setText("Tipo Pago:");

        tipoPagoCombo1.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Cheque", "Tarjeta", "Efectivo" }));
        tipoPagoCombo1.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                tipoPagoCombo1ActionPerformed(evt);
            }
        });

        jPanel22.setBorder(javax.swing.BorderFactory.createTitledBorder(null, "Tarjeta", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Tahoma", 1, 11))); // NOI18N

        jLabel48.setText("Tipo Tarjeta:");

        tipoTarjetaCombo1.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Crédito", "Débito" }));
        tipoTarjetaCombo1.setEnabled(false);

        jLabel49.setText("Número Tarjeta:");

        jLabel50.setText("Código Seguridad:");

        jLabel51.setText("Banco:");

        nombreBanco1.setEnabled(false);
        nombreBanco1.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                nombreBanco1ActionPerformed(evt);
            }
        });

        jLabel52.setText("Tipo Cuenta:");

        tipoCtaCombo1.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Corriente", "Ahorro" }));
        tipoCtaCombo1.setEnabled(false);

        codigoSeguridad1.setEnabled(false);

        numeroTarjeta1.setEnabled(false);

        limpiar11.setText("Limpiar");
        limpiar11.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                limpiar11ActionPerformed(evt);
            }
        });

        org.jdesktop.layout.GroupLayout jPanel22Layout = new org.jdesktop.layout.GroupLayout(jPanel22);
        jPanel22.setLayout(jPanel22Layout);
        jPanel22Layout.setHorizontalGroup(
            jPanel22Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel22Layout.createSequentialGroup()
                .add(jPanel22Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(org.jdesktop.layout.GroupLayout.TRAILING, jPanel22Layout.createSequentialGroup()
                        .add(36, 36, 36)
                        .add(jPanel22Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                            .add(jLabel52)
                            .add(jLabel48)
                            .add(jLabel49)
                            .add(jLabel50)
                            .add(jLabel51))
                        .add(36, 36, 36)
                        .add(jPanel22Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                            .add(jPanel22Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING, false)
                                .add(org.jdesktop.layout.GroupLayout.TRAILING, nombreBanco1)
                                .add(tipoCtaCombo1, 0, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                                .add(tipoTarjetaCombo1, 0, 144, Short.MAX_VALUE)
                                .add(numeroTarjeta1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 124, Short.MAX_VALUE))
                            .add(codigoSeguridad1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 144, Short.MAX_VALUE)))
                    .add(org.jdesktop.layout.GroupLayout.TRAILING, jPanel22Layout.createSequentialGroup()
                        .addContainerGap(239, Short.MAX_VALUE)
                        .add(limpiar11)))
                .addContainerGap())
        );
        jPanel22Layout.setVerticalGroup(
            jPanel22Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel22Layout.createSequentialGroup()
                .addContainerGap()
                .add(jPanel22Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(jLabel48)
                    .add(tipoTarjetaCombo1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                .add(jPanel22Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(jLabel52)
                    .add(tipoCtaCombo1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                .add(jPanel22Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(nombreBanco1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                    .add(jLabel51))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                .add(jPanel22Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(jLabel49)
                    .add(numeroTarjeta1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
                .add(13, 13, 13)
                .add(jPanel22Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(jLabel50)
                    .add(codigoSeguridad1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
                .add(18, 18, 18)
                .add(limpiar11)
                .addContainerGap(org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );

        jPanel38.setBorder(javax.swing.BorderFactory.createTitledBorder(null, "Cheque", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Tahoma", 1, 11))); // NOI18N

        jLabel54.setText("Banco:");

        jLabel55.setText("Número Cheque:");

        limpiar12.setText("Limpiar");
        limpiar12.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                limpiar12ActionPerformed(evt);
            }
        });

        org.jdesktop.layout.GroupLayout jPanel38Layout = new org.jdesktop.layout.GroupLayout(jPanel38);
        jPanel38.setLayout(jPanel38Layout);
        jPanel38Layout.setHorizontalGroup(
            jPanel38Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel38Layout.createSequentialGroup()
                .add(26, 26, 26)
                .add(jPanel38Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(jPanel38Layout.createSequentialGroup()
                        .add(jLabel55)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(numeroCheque1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 182, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
                    .add(org.jdesktop.layout.GroupLayout.TRAILING, limpiar12)
                    .add(org.jdesktop.layout.GroupLayout.TRAILING, jPanel38Layout.createSequentialGroup()
                        .add(jLabel54)
                        .add(52, 52, 52)
                        .add(nombreBancoCheque1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 182, Short.MAX_VALUE)))
                .addContainerGap())
        );
        jPanel38Layout.setVerticalGroup(
            jPanel38Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel38Layout.createSequentialGroup()
                .addContainerGap()
                .add(jPanel38Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(jLabel54)
                    .add(nombreBancoCheque1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                .add(jPanel38Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(jLabel55)
                    .add(numeroCheque1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED, 108, Short.MAX_VALUE)
                .add(limpiar12)
                .addContainerGap())
        );

        jLabel45.setFont(new java.awt.Font("Tahoma", 1, 11));
        jLabel45.setText("TOTAL A PAGAR Bs.F.:");

        totalPagoPorInsumo.setFont(new java.awt.Font("Tahoma", 1, 14));
        totalPagoPorInsumo.setForeground(new java.awt.Color(0, 153, 0));
        totalPagoPorInsumo.setText("0.0");

        org.jdesktop.layout.GroupLayout jPanel21Layout = new org.jdesktop.layout.GroupLayout(jPanel21);
        jPanel21.setLayout(jPanel21Layout);
        jPanel21Layout.setHorizontalGroup(
            jPanel21Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel21Layout.createSequentialGroup()
                .add(jPanel21Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(jPanel21Layout.createSequentialGroup()
                        .addContainerGap()
                        .add(jPanel22, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
                    .add(jPanel21Layout.createSequentialGroup()
                        .add(36, 36, 36)
                        .add(jLabel47)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                        .add(tipoPagoCombo1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 119, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                .add(jPanel21Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(jPanel21Layout.createSequentialGroup()
                        .add(jLabel45)
                        .add(29, 29, 29)
                        .add(totalPagoPorInsumo))
                    .add(jPanel38, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
                .addContainerGap())
        );
        jPanel21Layout.setVerticalGroup(
            jPanel21Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel21Layout.createSequentialGroup()
                .add(jPanel21Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(tipoPagoCombo1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                    .add(jLabel47)
                    .add(jLabel45)
                    .add(totalPagoPorInsumo))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                .add(jPanel21Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(jPanel38, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                    .add(jPanel22, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                .addContainerGap())
        );

        labelCancelado1.setFont(new java.awt.Font("Tahoma", 1, 20));
        labelCancelado1.setForeground(new java.awt.Color(0, 204, 0));
        labelCancelado1.setText("CANCELADO");
        labelCancelado1.setEnabled(false);

        jLabel121.setText("Duración del evento:");

        duracionEventoOrden.setText("0");

        jLabel124.setText("hora(s)");

        org.jdesktop.layout.GroupLayout jPanel19Layout = new org.jdesktop.layout.GroupLayout(jPanel19);
        jPanel19.setLayout(jPanel19Layout);
        jPanel19Layout.setHorizontalGroup(
            jPanel19Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(org.jdesktop.layout.GroupLayout.TRAILING, jPanel19Layout.createSequentialGroup()
                .addContainerGap(676, Short.MAX_VALUE)
                .add(insertarOrdenCompra)
                .addContainerGap())
            .add(jPanel19Layout.createSequentialGroup()
                .add(61, 61, 61)
                .add(jPanel21, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                .addContainerGap(27, Short.MAX_VALUE))
            .add(org.jdesktop.layout.GroupLayout.TRAILING, jPanel19Layout.createSequentialGroup()
                .addContainerGap()
                .add(jPanel18, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                .add(jPanel20, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                .addContainerGap())
            .add(jPanel19Layout.createSequentialGroup()
                .addContainerGap()
                .add(jPanel19Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(jPanel19Layout.createSequentialGroup()
                        .add(jLabel37)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(jcbEventosInsumosASubcontratar, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 185, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED))
                    .add(jPanel19Layout.createSequentialGroup()
                        .add(jLabel39)
                        .add(18, 18, 18)
                        .add(fechaInsumoSubcontrato)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED, 53, Short.MAX_VALUE)
                        .add(jLabel40)
                        .add(18, 18, 18)
                        .add(horaInicioEventosInsumo)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(jLabel44)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(horaFinEventosInsumo)
                        .add(31, 31, 31)))
                .add(jPanel19Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(jPanel19Layout.createSequentialGroup()
                        .add(jLabel121)
                        .add(18, 18, 18)
                        .add(duracionEventoOrden)
                        .add(18, 18, 18)
                        .add(jLabel124)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED, 46, Short.MAX_VALUE)
                        .add(labelCancelado1)
                        .add(22, 22, 22))
                    .add(jPanel19Layout.createSequentialGroup()
                        .add(mostrarOrdenCompra)
                        .addContainerGap(318, Short.MAX_VALUE))))
        );
        jPanel19Layout.setVerticalGroup(
            jPanel19Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(org.jdesktop.layout.GroupLayout.TRAILING, jPanel19Layout.createSequentialGroup()
                .addContainerGap()
                .add(jPanel19Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(jPanel19Layout.createSequentialGroup()
                        .add(jPanel19Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                            .add(jLabel37)
                            .add(jcbEventosInsumosASubcontratar, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
                        .add(14, 14, 14)
                        .add(jPanel19Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                            .add(jPanel19Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                                .add(jLabel39)
                                .add(fechaInsumoSubcontrato)
                                .add(jLabel40)
                                .add(horaInicioEventosInsumo)
                                .add(jLabel44)
                                .add(horaFinEventosInsumo)
                                .add(jLabel121)
                                .add(duracionEventoOrden)
                                .add(jLabel124))
                            .add(labelCancelado1)))
                    .add(mostrarOrdenCompra, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 23, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                .add(jPanel19Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING, false)
                    .add(jPanel18, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .add(jPanel20, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                .add(jPanel21, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 292, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                .add(insertarOrdenCompra)
                .addContainerGap())
        );

        org.jdesktop.layout.GroupLayout jPanel4Layout = new org.jdesktop.layout.GroupLayout(jPanel4);
        jPanel4.setLayout(jPanel4Layout);
        jPanel4Layout.setHorizontalGroup(
            jPanel4Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel4Layout.createSequentialGroup()
                .add(jPanel19, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 795, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                .addContainerGap(66, Short.MAX_VALUE))
        );
        jPanel4Layout.setVerticalGroup(
            jPanel4Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel4Layout.createSequentialGroup()
                .addContainerGap()
                .add(jPanel19, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 603, Short.MAX_VALUE)
                .addContainerGap())
        );

        jTabbedPane1.addTab("Solicitud de la Orden de Compra", jPanel4);

        jPanel23.setBorder(javax.swing.BorderFactory.createTitledBorder(""));
        jPanel23.setFont(new java.awt.Font("Microsoft Sans Serif", 0, 12));
        jPanel23.setPreferredSize(new java.awt.Dimension(810, 283));

        tablaInsumosSubcontratados.setModel(new javax.swing.table.DefaultTableModel(
            new Object [][] {

            },
            new String [] {
                "Fecha", "Cantidad", "Concepto", "Costo Unitario", "Monto"
            }
        ) {
            boolean[] canEdit = new boolean [] {
                false, false, false, false, false
            };

            public boolean isCellEditable(int rowIndex, int columnIndex) {
                return canEdit [columnIndex];
            }
        });
        jScrollPane5.setViewportView(tablaInsumosSubcontratados);

        mostrarReciboPago.setIcon(new javax.swing.ImageIcon(getClass().getResource("/Iconos/search.png"))); // NOI18N

        binding = org.jdesktop.beansbinding.Bindings.createAutoBinding(org.jdesktop.beansbinding.AutoBinding.UpdateStrategy.READ_WRITE, mostrarReciboPago, org.jdesktop.beansbinding.ELProperty.create("Haga click en el botón para consultar los recibos de pago de los eventos que subcontrataron"), mostrarReciboPago, org.jdesktop.beansbinding.BeanProperty.create("toolTipText"));
        bindingGroup.addBinding(binding);

        mostrarReciboPago.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                mostrarReciboPagoActionPerformed(evt);
            }
        });

        jLabel66.setIcon(new javax.swing.ImageIcon(getClass().getResource("/Iconos/Recibo.PNG"))); // NOI18N

        jLabel67.setFont(new java.awt.Font("Tahoma", 1, 11));
        jLabel67.setText("SELECCIONE EL EVENTO A CONSULTAR:");

        jcbInsumosSubcontratados.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jcbInsumosSubcontratadosActionPerformed(evt);
            }
        });

        jLabel72.setFont(new java.awt.Font("Tahoma", 1, 11));
        jLabel72.setText("Proveedores solicitados para ese evento:");

        jcbProveedoresRecibo.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jcbProveedoresReciboActionPerformed(evt);
            }
        });

        jPanel35.setBorder(javax.swing.BorderFactory.createTitledBorder("Información del Proveedor"));

        jLabel115.setText("Dirección:");

        jLabel116.setText("Teléfono:");

        jLabel117.setText("Cantidad insumos subcontratados:");

        jLabel71.setText("Total pagado al proveedor   Bs.F.:");

        totalPagoPorProveedorRecibo.setFont(new java.awt.Font("Tahoma", 0, 12));
        totalPagoPorProveedorRecibo.setText("0.0");

        cantidadInsumosProveedor.setText("0");

        direccionProveedorRecibo.setText("dirección");

        telefonoProveedorRecibo.setText("teléfono");

        org.jdesktop.layout.GroupLayout jPanel35Layout = new org.jdesktop.layout.GroupLayout(jPanel35);
        jPanel35.setLayout(jPanel35Layout);
        jPanel35Layout.setHorizontalGroup(
            jPanel35Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel35Layout.createSequentialGroup()
                .addContainerGap()
                .add(jPanel35Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(jPanel35Layout.createSequentialGroup()
                        .add(jLabel115)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(direccionProveedorRecibo))
                    .add(jPanel35Layout.createSequentialGroup()
                        .add(jLabel116)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                        .add(telefonoProveedorRecibo))
                    .add(jPanel35Layout.createSequentialGroup()
                        .add(jPanel35Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                            .add(jLabel117)
                            .add(jLabel71))
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED, 77, Short.MAX_VALUE)
                        .add(jPanel35Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING)
                            .add(totalPagoPorProveedorRecibo)
                            .add(cantidadInsumosProveedor))))
                .addContainerGap())
        );
        jPanel35Layout.setVerticalGroup(
            jPanel35Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel35Layout.createSequentialGroup()
                .add(jPanel35Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(jPanel35Layout.createSequentialGroup()
                        .add(jPanel35Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                            .add(jLabel115)
                            .add(direccionProveedorRecibo))
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                        .add(jPanel35Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                            .add(jLabel116)
                            .add(telefonoProveedorRecibo))
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                        .add(jLabel117)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                        .add(jLabel71))
                    .add(jPanel35Layout.createSequentialGroup()
                        .add(50, 50, 50)
                        .add(cantidadInsumosProveedor)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                        .add(totalPagoPorProveedorRecibo)))
                .addContainerGap(org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );

        jPanel33.setBorder(javax.swing.BorderFactory.createTitledBorder("Información General"));

        jLabel68.setText("Fecha del evento:");

        fechaInsumoSubcontratados.setText("----/--/--");

        jLabel69.setText("Hora del evento:");

        horaInicioEventosInsumoSubcontratado.setText("00:00");

        jLabel70.setText("a");

        horaFinEventosInsumoSubcontratado.setText("00:00");

        jLabel74.setText("Total insumos subcontratados para el evento:");

        labelTotalInsumos.setFont(new java.awt.Font("Tahoma", 0, 12));
        labelTotalInsumos.setText("0");

        totalSubcontratadoRecibo.setFont(new java.awt.Font("Tahoma", 1, 14));
        totalSubcontratadoRecibo.setForeground(new java.awt.Color(0, 153, 0));
        totalSubcontratadoRecibo.setText("0.0");

        jLabel73.setText("Total subcontratado    Bs.F.:");

        org.jdesktop.layout.GroupLayout jPanel33Layout = new org.jdesktop.layout.GroupLayout(jPanel33);
        jPanel33.setLayout(jPanel33Layout);
        jPanel33Layout.setHorizontalGroup(
            jPanel33Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel33Layout.createSequentialGroup()
                .addContainerGap()
                .add(jPanel33Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(jPanel33Layout.createSequentialGroup()
                        .add(jPanel33Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                            .add(jLabel73)
                            .add(jLabel74))
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED, 94, Short.MAX_VALUE)
                        .add(jPanel33Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                            .add(org.jdesktop.layout.GroupLayout.TRAILING, totalSubcontratadoRecibo)
                            .add(org.jdesktop.layout.GroupLayout.TRAILING, labelTotalInsumos)))
                    .add(jPanel33Layout.createSequentialGroup()
                        .add(jPanel33Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                            .add(jLabel68)
                            .add(jLabel69))
                        .add(18, 18, 18)
                        .add(jPanel33Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                            .add(fechaInsumoSubcontratados)
                            .add(jPanel33Layout.createSequentialGroup()
                                .add(2, 2, 2)
                                .add(horaInicioEventosInsumoSubcontratado)
                                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                                .add(jLabel70)
                                .add(10, 10, 10)
                                .add(horaFinEventosInsumoSubcontratado)))))
                .addContainerGap())
        );
        jPanel33Layout.setVerticalGroup(
            jPanel33Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel33Layout.createSequentialGroup()
                .add(jPanel33Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(jPanel33Layout.createSequentialGroup()
                        .add(jPanel33Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                            .add(jPanel33Layout.createSequentialGroup()
                                .add(jLabel68)
                                .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                                .add(jLabel69))
                            .add(jPanel33Layout.createSequentialGroup()
                                .add(fechaInsumoSubcontratados)
                                .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                                .add(jPanel33Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                                    .add(horaInicioEventosInsumoSubcontratado)
                                    .add(horaFinEventosInsumoSubcontratado)
                                    .add(jLabel70))))
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED, 12, Short.MAX_VALUE)
                        .add(jLabel74)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                        .add(jLabel73))
                    .add(org.jdesktop.layout.GroupLayout.TRAILING, jPanel33Layout.createSequentialGroup()
                        .addContainerGap(47, Short.MAX_VALUE)
                        .add(labelTotalInsumos)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                        .add(totalSubcontratadoRecibo)))
                .addContainerGap())
        );

        org.jdesktop.layout.GroupLayout jPanel23Layout = new org.jdesktop.layout.GroupLayout(jPanel23);
        jPanel23.setLayout(jPanel23Layout);
        jPanel23Layout.setHorizontalGroup(
            jPanel23Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel23Layout.createSequentialGroup()
                .addContainerGap()
                .add(jPanel23Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(jPanel23Layout.createSequentialGroup()
                        .add(jPanel23Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                            .add(jPanel23Layout.createSequentialGroup()
                                .add(jLabel67)
                                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                                .add(jcbInsumosSubcontratados, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 201, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                                .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                                .add(mostrarReciboPago))
                            .add(jLabel72)
                            .add(jcbProveedoresRecibo, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 200, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                            .add(jScrollPane5, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 675, Short.MAX_VALUE)
                            .add(jPanel23Layout.createSequentialGroup()
                                .add(jPanel35, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                                .add(jPanel33, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)))
                        .addContainerGap())
                    .add(org.jdesktop.layout.GroupLayout.TRAILING, jLabel66)))
        );
        jPanel23Layout.setVerticalGroup(
            jPanel23Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel23Layout.createSequentialGroup()
                .add(jPanel23Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(jPanel23Layout.createSequentialGroup()
                        .addContainerGap()
                        .add(jPanel23Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                            .add(jPanel23Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                                .add(jLabel67)
                                .add(jcbInsumosSubcontratados, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
                            .add(mostrarReciboPago))
                        .add(18, 18, 18)
                        .add(jLabel72)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                        .add(jcbProveedoresRecibo, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
                    .add(jLabel66))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                .add(jPanel23Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(jPanel33, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .add(jPanel35, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                .add(jScrollPane5, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 202, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                .add(144, 144, 144))
        );

        org.jdesktop.layout.GroupLayout jPanel5Layout = new org.jdesktop.layout.GroupLayout(jPanel5);
        jPanel5.setLayout(jPanel5Layout);
        jPanel5Layout.setHorizontalGroup(
            jPanel5Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel5Layout.createSequentialGroup()
                .add(74, 74, 74)
                .add(jPanel23, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 711, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                .addContainerGap(76, Short.MAX_VALUE))
        );
        jPanel5Layout.setVerticalGroup(
            jPanel5Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel5Layout.createSequentialGroup()
                .addContainerGap()
                .add(jPanel23, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 602, Short.MAX_VALUE)
                .addContainerGap())
        );

        jTabbedPane1.addTab("Recibo de Pago", jPanel5);

        jPanel13.setBorder(javax.swing.BorderFactory.createTitledBorder(""));

        jLabel75.setFont(new java.awt.Font("Tahoma", 1, 11));
        jLabel75.setText("SELECCIONE EL EVENTO A CONSULTAR:");

        idEventosCuadre.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                idEventosCuadreActionPerformed(evt);
            }
        });

        mostrarCuadreGanancia.setIcon(new javax.swing.ImageIcon(getClass().getResource("/Iconos/search.png"))); // NOI18N

        binding = org.jdesktop.beansbinding.Bindings.createAutoBinding(org.jdesktop.beansbinding.AutoBinding.UpdateStrategy.READ_WRITE, mostrarCuadreGanancia, org.jdesktop.beansbinding.ELProperty.create("Haga click en el botón para consultar el cuadre de ganancias del evento"), mostrarCuadreGanancia, org.jdesktop.beansbinding.BeanProperty.create("toolTipText"));
        bindingGroup.addBinding(binding);

        mostrarCuadreGanancia.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                mostrarCuadreGananciaActionPerformed(evt);
            }
        });

        jPanel24.setBorder(javax.swing.BorderFactory.createTitledBorder(null, "Información del Evento", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Tahoma", 1, 11))); // NOI18N

        jLabel76.setText("Fecha del Evento:");

        jLabel77.setText("Ejecutivo Encargado:");

        fechaEventoCuadre.setText("----/--/--");

        ejecutivoEncargadoCuadre.setText("Ejecutivo Encargado");

        jLabel78.setText("Hora del evento:");

        horaInicioCuadre.setText("00:00");

        jLabel79.setText("a");

        horaFinCuadre.setText("00:00");

        org.jdesktop.layout.GroupLayout jPanel24Layout = new org.jdesktop.layout.GroupLayout(jPanel24);
        jPanel24.setLayout(jPanel24Layout);
        jPanel24Layout.setHorizontalGroup(
            jPanel24Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel24Layout.createSequentialGroup()
                .addContainerGap()
                .add(jPanel24Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(jPanel24Layout.createSequentialGroup()
                        .add(jLabel76)
                        .add(26, 26, 26)
                        .add(fechaEventoCuadre))
                    .add(jPanel24Layout.createSequentialGroup()
                        .add(jLabel78)
                        .add(25, 25, 25)
                        .add(horaInicioCuadre)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(jLabel79)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(horaFinCuadre))
                    .add(jPanel24Layout.createSequentialGroup()
                        .add(jLabel77)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(ejecutivoEncargadoCuadre)))
                .addContainerGap(34, Short.MAX_VALUE))
        );
        jPanel24Layout.setVerticalGroup(
            jPanel24Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(org.jdesktop.layout.GroupLayout.TRAILING, jPanel24Layout.createSequentialGroup()
                .addContainerGap()
                .add(jPanel24Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(jLabel76)
                    .add(fechaEventoCuadre))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                .add(jPanel24Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(jLabel78)
                    .add(jLabel79)
                    .add(horaFinCuadre)
                    .add(horaInicioCuadre))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED, 18, Short.MAX_VALUE)
                .add(jPanel24Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(jLabel77)
                    .add(ejecutivoEncargadoCuadre))
                .addContainerGap())
        );

        jPanel29.setBorder(javax.swing.BorderFactory.createTitledBorder(null, "Cliente", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Tahoma", 1, 11))); // NOI18N

        jLabel89.setText("Nombre del Cliente:");

        nombreClienteCuadre.setText("Nombre Cliente");

        telefonoCuadre.setText("teléfono");

        jLabel90.setText("Teléfono:");

        rifCuadre.setText("--");

        jLabel91.setText("RIF:");

        ciCuadre.setText("--");

        jLabel92.setText("C.I.:");

        org.jdesktop.layout.GroupLayout jPanel29Layout = new org.jdesktop.layout.GroupLayout(jPanel29);
        jPanel29.setLayout(jPanel29Layout);
        jPanel29Layout.setHorizontalGroup(
            jPanel29Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel29Layout.createSequentialGroup()
                .addContainerGap()
                .add(jPanel29Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(nombreClienteCuadre)
                    .add(jPanel29Layout.createSequentialGroup()
                        .add(jLabel92)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(ciCuadre))
                    .add(jPanel29Layout.createSequentialGroup()
                        .add(jLabel91)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(rifCuadre))
                    .add(jPanel29Layout.createSequentialGroup()
                        .add(jLabel90)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(telefonoCuadre))
                    .add(jLabel89))
                .addContainerGap(97, Short.MAX_VALUE))
        );
        jPanel29Layout.setVerticalGroup(
            jPanel29Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(org.jdesktop.layout.GroupLayout.TRAILING, jPanel29Layout.createSequentialGroup()
                .addContainerGap()
                .add(jLabel89)
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .add(nombreClienteCuadre)
                .add(18, 18, 18)
                .add(jPanel29Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(jLabel92)
                    .add(ciCuadre))
                .add(12, 12, 12)
                .add(jPanel29Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(rifCuadre)
                    .add(jLabel91))
                .add(21, 21, 21)
                .add(jPanel29Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(jLabel90)
                    .add(telefonoCuadre))
                .addContainerGap())
        );

        jPanel25.setBorder(javax.swing.BorderFactory.createTitledBorder(null, "Reporte", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Tahoma", 1, 11))); // NOI18N

        jLabel94.setText("-  Monto Total Gastado Bs.F.:");

        montoTotalPerdido.setForeground(new java.awt.Color(204, 0, 0));
        montoTotalPerdido.setText("0.0");

        jLabel93.setFont(new java.awt.Font("Tahoma", 1, 12));
        jLabel93.setText("Bs.F.:");

        montoTotalGanado.setFont(new java.awt.Font("Tahoma", 1, 12));
        montoTotalGanado.setForeground(new java.awt.Color(153, 153, 153));
        montoTotalGanado.setText("0.0");

        jLabel106.setFont(new java.awt.Font("Tahoma", 0, 12));
        jLabel106.setText("En este evento se ha ");

        labelGanadoPerdido.setFont(new java.awt.Font("Tahoma", 1, 12));
        labelGanadoPerdido.setText("       ");

        jLabel107.setFont(new java.awt.Font("Tahoma", 0, 12));
        jLabel107.setText("total de ");

        jLabel108.setFont(new java.awt.Font("Tahoma", 0, 12));
        jLabel108.setText("un monto");

        jLabel85.setIcon(new javax.swing.ImageIcon(getClass().getResource("/Iconos/lists_1.png"))); // NOI18N

        jLabel113.setText("-  Pago a Contratados Bs.F.:");

        gastoContratados.setForeground(new java.awt.Color(204, 0, 0));
        gastoContratados.setText("0.0");

        org.jdesktop.layout.GroupLayout jPanel25Layout = new org.jdesktop.layout.GroupLayout(jPanel25);
        jPanel25.setLayout(jPanel25Layout);
        jPanel25Layout.setHorizontalGroup(
            jPanel25Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel25Layout.createSequentialGroup()
                .add(jPanel25Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(jPanel25Layout.createSequentialGroup()
                        .addContainerGap()
                        .add(jLabel85)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(jPanel25Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                            .add(jLabel94)
                            .add(jLabel113))
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(jPanel25Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                            .add(org.jdesktop.layout.GroupLayout.TRAILING, montoTotalPerdido)
                            .add(org.jdesktop.layout.GroupLayout.TRAILING, gastoContratados)))
                    .add(jPanel25Layout.createSequentialGroup()
                        .add(48, 48, 48)
                        .add(jLabel107)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(jLabel93)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(montoTotalGanado))
                    .add(jPanel25Layout.createSequentialGroup()
                        .add(48, 48, 48)
                        .add(jLabel106)
                        .add(2, 2, 2)
                        .add(labelGanadoPerdido, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 52, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(jLabel108)))
                .addContainerGap())
        );

        jPanel25Layout.linkSize(new java.awt.Component[] {gastoContratados, montoTotalPerdido}, org.jdesktop.layout.GroupLayout.HORIZONTAL);

        jPanel25Layout.setVerticalGroup(
            jPanel25Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel25Layout.createSequentialGroup()
                .addContainerGap()
                .add(jPanel25Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(org.jdesktop.layout.GroupLayout.TRAILING, jPanel25Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                        .add(jLabel94)
                        .add(jPanel25Layout.createSequentialGroup()
                            .add(20, 20, 20)
                            .add(jLabel113))
                        .add(jPanel25Layout.createSequentialGroup()
                            .add(montoTotalPerdido)
                            .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                            .add(gastoContratados)))
                    .add(org.jdesktop.layout.GroupLayout.TRAILING, jLabel85))
                .add(31, 31, 31)
                .add(jPanel25Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(jLabel106)
                    .add(jLabel108)
                    .add(labelGanadoPerdido))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                .add(jPanel25Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(jLabel107)
                    .add(jLabel93)
                    .add(montoTotalGanado))
                .addContainerGap(37, Short.MAX_VALUE))
        );

        jPanel26.setBorder(javax.swing.BorderFactory.createTitledBorder(null, "Insumos Facturados", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Tahoma", 1, 11))); // NOI18N

        tablaFacturaCuadre.setModel(new javax.swing.table.DefaultTableModel(
            new Object [][] {

            },
            new String [] {
                "Cantidad", "Concepto", "Costo Unitario", "Monto"
            }
        ) {
            boolean[] canEdit = new boolean [] {
                false, false, false, false
            };

            public boolean isCellEditable(int rowIndex, int columnIndex) {
                return canEdit [columnIndex];
            }
        });
        tablaFacturaCuadre.getTableHeader().setReorderingAllowed(false);
        jScrollPane6.setViewportView(tablaFacturaCuadre);

        jLabel82.setFont(new java.awt.Font("Tahoma", 0, 10));
        jLabel82.setText("Sub - TOTAL BsF.");

        jLabel86.setFont(new java.awt.Font("Tahoma", 0, 10));
        jLabel86.setText("IVA 9% BsF.");

        jLabel87.setFont(new java.awt.Font("Tahoma", 0, 10));
        jLabel87.setText("5% Deposito por Averias BsF.");

        jLabel88.setFont(new java.awt.Font("Tahoma", 1, 11));
        jLabel88.setText("TOTAL Facturado Bs.F.:");

        pagoTotalLabelCuadre.setFont(new java.awt.Font("Tahoma", 1, 11));
        pagoTotalLabelCuadre.setText("0.0");

        depositoCuadre.setFont(new java.awt.Font("Tahoma", 0, 10));
        depositoCuadre.setHorizontalAlignment(javax.swing.SwingConstants.RIGHT);
        depositoCuadre.setText("0.0");

        ivaCuadre.setFont(new java.awt.Font("Tahoma", 0, 10));
        ivaCuadre.setHorizontalAlignment(javax.swing.SwingConstants.RIGHT);
        ivaCuadre.setText("0.0");

        subtotalCuadre.setFont(new java.awt.Font("Tahoma", 0, 10));
        subtotalCuadre.setHorizontalAlignment(javax.swing.SwingConstants.RIGHT);
        subtotalCuadre.setText("0.0");
        subtotalCuadre.setHorizontalTextPosition(javax.swing.SwingConstants.RIGHT);

        jLabel80.setText("-    Cantidad Insumos Facturados:");

        totalInsumoFacturado.setFont(new java.awt.Font("Tahoma", 0, 12));
        totalInsumoFacturado.setText("0");

        org.jdesktop.layout.GroupLayout jPanel26Layout = new org.jdesktop.layout.GroupLayout(jPanel26);
        jPanel26.setLayout(jPanel26Layout);
        jPanel26Layout.setHorizontalGroup(
            jPanel26Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel26Layout.createSequentialGroup()
                .addContainerGap()
                .add(jScrollPane6, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 501, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                .add(jPanel26Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING)
                    .add(org.jdesktop.layout.GroupLayout.LEADING, jPanel26Layout.createSequentialGroup()
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(jLabel80))
                    .add(org.jdesktop.layout.GroupLayout.LEADING, jPanel26Layout.createSequentialGroup()
                        .add(18, 18, 18)
                        .add(jPanel26Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                            .add(jLabel82)
                            .add(jLabel86)
                            .add(jLabel87)
                            .add(jLabel88))))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED, 35, Short.MAX_VALUE)
                .add(jPanel26Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(org.jdesktop.layout.GroupLayout.TRAILING, totalInsumoFacturado)
                    .add(org.jdesktop.layout.GroupLayout.TRAILING, subtotalCuadre)
                    .add(org.jdesktop.layout.GroupLayout.TRAILING, ivaCuadre)
                    .add(org.jdesktop.layout.GroupLayout.TRAILING, depositoCuadre)
                    .add(org.jdesktop.layout.GroupLayout.TRAILING, pagoTotalLabelCuadre))
                .add(59, 59, 59))
        );

        jPanel26Layout.linkSize(new java.awt.Component[] {depositoCuadre, ivaCuadre, subtotalCuadre}, org.jdesktop.layout.GroupLayout.HORIZONTAL);

        jPanel26Layout.setVerticalGroup(
            jPanel26Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel26Layout.createSequentialGroup()
                .add(jPanel26Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(jScrollPane6, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 146, Short.MAX_VALUE)
                    .add(jPanel26Layout.createSequentialGroup()
                        .add(jLabel80)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED, 50, Short.MAX_VALUE)
                        .add(jLabel82)
                        .add(5, 5, 5)
                        .add(jLabel86)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(jLabel87)
                        .add(18, 18, 18)
                        .add(jLabel88))
                    .add(org.jdesktop.layout.GroupLayout.TRAILING, jPanel26Layout.createSequentialGroup()
                        .add(1, 1, 1)
                        .add(totalInsumoFacturado)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED, 48, Short.MAX_VALUE)
                        .add(subtotalCuadre)
                        .add(5, 5, 5)
                        .add(ivaCuadre)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(depositoCuadre)
                        .add(18, 18, 18)
                        .add(pagoTotalLabelCuadre)))
                .addContainerGap())
        );

        jPanel28.setBorder(javax.swing.BorderFactory.createTitledBorder(null, "Insumos Subcontratados", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Tahoma", 1, 11))); // NOI18N

        tablaInsumosSubcontratadosCuadre.setModel(new javax.swing.table.DefaultTableModel(
            new Object [][] {

            },
            new String [] {
                "Cantidad", "Concepto", "Costo Unitario", "Monto"
            }
        ) {
            boolean[] canEdit = new boolean [] {
                false, false, false, false
            };

            public boolean isCellEditable(int rowIndex, int columnIndex) {
                return canEdit [columnIndex];
            }
        });
        tablaInsumosSubcontratadosCuadre.getTableHeader().setReorderingAllowed(false);
        jScrollPane7.setViewportView(tablaInsumosSubcontratadosCuadre);

        jLabel84.setFont(new java.awt.Font("Tahoma", 1, 11));
        jLabel84.setText("Proveedores solicitados:");

        jcbProveedoresCuadre.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jcbProveedoresCuadreActionPerformed(evt);
            }
        });

        jLabel83.setFont(new java.awt.Font("Tahoma", 1, 11));
        jLabel83.setText("Pago al Proveedor   Bs.F.:");

        totalPagoPorProveedorCuadre.setFont(new java.awt.Font("Tahoma", 1, 11));
        totalPagoPorProveedorCuadre.setText("0.0");

        jLabel81.setText("-    Cantidad Insumos Subcontratados:");

        totalInsumoSubcontratado.setFont(new java.awt.Font("Tahoma", 0, 12));
        totalInsumoSubcontratado.setText("0");

        org.jdesktop.layout.GroupLayout jPanel28Layout = new org.jdesktop.layout.GroupLayout(jPanel28);
        jPanel28.setLayout(jPanel28Layout);
        jPanel28Layout.setHorizontalGroup(
            jPanel28Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel28Layout.createSequentialGroup()
                .addContainerGap()
                .add(jScrollPane7, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 500, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                .add(jPanel28Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(jPanel28Layout.createSequentialGroup()
                        .add(jPanel28Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                            .add(jLabel81)
                            .add(jLabel83))
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                        .add(jPanel28Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                            .add(org.jdesktop.layout.GroupLayout.TRAILING, totalInsumoSubcontratado)
                            .add(org.jdesktop.layout.GroupLayout.TRAILING, totalPagoPorProveedorCuadre)))
                    .add(jcbProveedoresCuadre, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 185, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                    .add(jLabel84))
                .add(57, 57, 57))
        );
        jPanel28Layout.setVerticalGroup(
            jPanel28Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel28Layout.createSequentialGroup()
                .add(jPanel28Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(org.jdesktop.layout.GroupLayout.TRAILING, jScrollPane7, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 148, Short.MAX_VALUE)
                    .add(jPanel28Layout.createSequentialGroup()
                        .add(jLabel84)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                        .add(jcbProveedoresCuadre, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(jPanel28Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                            .add(jPanel28Layout.createSequentialGroup()
                                .add(totalInsumoSubcontratado)
                                .add(35, 35, 35)
                                .add(totalPagoPorProveedorCuadre))
                            .add(jPanel28Layout.createSequentialGroup()
                                .add(jLabel81)
                                .add(35, 35, 35)
                                .add(jLabel83)))))
                .addContainerGap())
        );

        org.jdesktop.layout.GroupLayout jPanel13Layout = new org.jdesktop.layout.GroupLayout(jPanel13);
        jPanel13.setLayout(jPanel13Layout);
        jPanel13Layout.setHorizontalGroup(
            jPanel13Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel13Layout.createSequentialGroup()
                .addContainerGap()
                .add(jPanel13Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING)
                    .add(org.jdesktop.layout.GroupLayout.LEADING, jPanel28, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 805, Short.MAX_VALUE)
                    .add(org.jdesktop.layout.GroupLayout.LEADING, jPanel26, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .add(jPanel13Layout.createSequentialGroup()
                        .add(jPanel13Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                            .add(jPanel13Layout.createSequentialGroup()
                                .add(jPanel13Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                                    .add(jLabel75)
                                    .add(idEventosCuadre, 0, 211, Short.MAX_VALUE))
                                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                                .add(mostrarCuadreGanancia, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 44, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                                .add(11, 11, 11))
                            .add(jPanel13Layout.createSequentialGroup()
                                .add(jPanel24, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)))
                        .add(jPanel29, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(jPanel25, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)))
                .addContainerGap())
        );
        jPanel13Layout.setVerticalGroup(
            jPanel13Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel13Layout.createSequentialGroup()
                .addContainerGap()
                .add(jPanel13Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING, false)
                    .add(jPanel13Layout.createSequentialGroup()
                        .add(jLabel75)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(jPanel13Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING, false)
                            .add(mostrarCuadreGanancia, 0, 0, Short.MAX_VALUE)
                            .add(idEventosCuadre, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
                        .add(15, 15, 15)
                        .add(jPanel24, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
                    .add(jPanel29, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .add(jPanel25, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .add(jPanel26, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                .add(jPanel28, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                .add(11, 11, 11))
        );

        jPanel13Layout.linkSize(new java.awt.Component[] {idEventosCuadre, mostrarCuadreGanancia}, org.jdesktop.layout.GroupLayout.VERTICAL);

        org.jdesktop.layout.GroupLayout jPanel12Layout = new org.jdesktop.layout.GroupLayout(jPanel12);
        jPanel12.setLayout(jPanel12Layout);
        jPanel12Layout.setHorizontalGroup(
            jPanel12Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel12Layout.createSequentialGroup()
                .add(jPanel13, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .add(20, 20, 20))
        );
        jPanel12Layout.setVerticalGroup(
            jPanel12Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel12Layout.createSequentialGroup()
                .addContainerGap()
                .add(jPanel13, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .add(8, 8, 8))
        );

        jTabbedPane1.addTab("Cuadre de Ganancias", jPanel12);

        jPanel34.setBorder(javax.swing.BorderFactory.createTitledBorder(""));
        jPanel34.setFont(new java.awt.Font("Microsoft Sans Serif", 0, 12));
        jPanel34.setPreferredSize(new java.awt.Dimension(810, 283));

        consultarEstadistica.setIcon(new javax.swing.ImageIcon(getClass().getResource("/Iconos/search.png"))); // NOI18N

        binding = org.jdesktop.beansbinding.Bindings.createAutoBinding(org.jdesktop.beansbinding.AutoBinding.UpdateStrategy.READ_WRITE, consultarEstadistica, org.jdesktop.beansbinding.ELProperty.create("Haga click en el botón para consultar las estadísticas del mes"), consultarEstadistica, org.jdesktop.beansbinding.BeanProperty.create("toolTipText"), consultarEstadistica.getToolTipText());
        bindingGroup.addBinding(binding);

        consultarEstadistica.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                consultarEstadisticaActionPerformed(evt);
            }
        });

        jPanel31.setBorder(javax.swing.BorderFactory.createTitledBorder(null, "Seleccione el evento deseado para mostrar más información", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Tahoma", 1, 11))); // NOI18N

        jLabel99.setText("Hora del Evento:");

        horaInicioEstadistica.setText("00:00");

        jLabel100.setText("Nombre del Cliente:");

        nombreClienteEstadistica.setText("Nombre Cliente");

        jLabel101.setText("RIF o C.I.:");

        ciEstadistica.setText("--");

        jLabel103.setText("Teléfono del Cliente:");

        telefonoEstadistica.setText("teléfono");

        jLabel96.setText("Ejecutivo Encargado:");

        ejecutivoEncargadoEstadistica.setText("Ejecutivo Encargado");

        jLabel127.setIcon(new javax.swing.ImageIcon(getClass().getResource("/Iconos/edit_user.png"))); // NOI18N

        jLabel98.setText("a");

        horaFinEstadistica.setText("00:00");

        jLabel129.setText("Fecha del Evento:");

        fechaEventoEstadistica.setText("----/--/--");

        org.jdesktop.layout.GroupLayout jPanel31Layout = new org.jdesktop.layout.GroupLayout(jPanel31);
        jPanel31.setLayout(jPanel31Layout);
        jPanel31Layout.setHorizontalGroup(
            jPanel31Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel31Layout.createSequentialGroup()
                .addContainerGap()
                .add(jLabel127)
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                .add(jPanel31Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(jPanel31Layout.createSequentialGroup()
                        .add(jLabel99)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(horaInicioEstadistica)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                        .add(jLabel98)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                        .add(horaFinEstadistica))
                    .add(jPanel31Layout.createSequentialGroup()
                        .add(jLabel129)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(fechaEventoEstadistica))
                    .add(jPanel31Layout.createSequentialGroup()
                        .add(jLabel96)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(ejecutivoEncargadoEstadistica))
                    .add(jPanel31Layout.createSequentialGroup()
                        .add(jLabel103)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(telefonoEstadistica))
                    .add(jPanel31Layout.createSequentialGroup()
                        .add(jLabel100)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(nombreClienteEstadistica))
                    .add(jPanel31Layout.createSequentialGroup()
                        .add(jLabel101)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(ciEstadistica)))
                .add(123, 123, 123))
        );
        jPanel31Layout.setVerticalGroup(
            jPanel31Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel31Layout.createSequentialGroup()
                .addContainerGap()
                .add(jPanel31Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(jPanel31Layout.createSequentialGroup()
                        .add(jPanel31Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                            .add(nombreClienteEstadistica)
                            .add(jLabel100))
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                        .add(jPanel31Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                            .add(jLabel101)
                            .add(ciEstadistica))
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                        .add(jPanel31Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                            .add(jLabel103)
                            .add(telefonoEstadistica)))
                    .add(jLabel127))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                .add(jPanel31Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(jLabel96)
                    .add(ejecutivoEncargadoEstadistica))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED, 12, Short.MAX_VALUE)
                .add(jPanel31Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(jLabel129)
                    .add(fechaEventoEstadistica))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                .add(jPanel31Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING)
                    .add(jPanel31Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                        .add(horaInicioEstadistica)
                        .add(jLabel98)
                        .add(horaFinEstadistica))
                    .add(jLabel99))
                .add(25, 25, 25))
        );

        jLabel104.setFont(new java.awt.Font("Tahoma", 1, 11));
        jLabel104.setText("SELECCIONE EL MES A CONSULTAR:");

        jPanel32.setBorder(javax.swing.BorderFactory.createTitledBorder(null, "Detalles de los eventos", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Tahoma", 1, 11))); // NOI18N

        tablaEstadisticas.setModel(new javax.swing.table.DefaultTableModel(
            new Object [][] {

            },
            new String [] {
                "Código", "Nombre del Evento", "Monto Cotizado", "Monto Subcontratado", "Pago Personas Contratadas"
            }
        ) {
            boolean[] canEdit = new boolean [] {
                false, false, false, false, false
            };

            public boolean isCellEditable(int rowIndex, int columnIndex) {
                return canEdit [columnIndex];
            }
        });
        tablaEstadisticas.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                tablaEstadisticasMouseClicked(evt);
            }
        });
        jScrollPane12.setViewportView(tablaEstadisticas);

        org.jdesktop.layout.GroupLayout jPanel32Layout = new org.jdesktop.layout.GroupLayout(jPanel32);
        jPanel32.setLayout(jPanel32Layout);
        jPanel32Layout.setHorizontalGroup(
            jPanel32Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel32Layout.createSequentialGroup()
                .addContainerGap()
                .add(jScrollPane12, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 688, Short.MAX_VALUE)
                .addContainerGap())
        );
        jPanel32Layout.setVerticalGroup(
            jPanel32Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel32Layout.createSequentialGroup()
                .add(jScrollPane12, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 156, Short.MAX_VALUE)
                .addContainerGap())
        );

        jPanel30.setBorder(javax.swing.BorderFactory.createTitledBorder(null, "Análisis", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Tahoma", 1, 11))); // NOI18N

        jLabel95.setText("Monto total cotizado Bs.F.:");

        jLabel97.setText("-    Monto total subcontratado Bs.F.:");

        jLabel102.setFont(new java.awt.Font("Tahoma", 1, 11));
        jLabel102.setText("Total Ganancia Neta Bs.F.:");

        jLabel105.setFont(new java.awt.Font("Tahoma", 1, 11));
        jLabel105.setText("Total Perdida Neta Bs.F.:");

        montoCotizadoPorMes.setText("0.0");

        montoSubcontratadoPorMes.setForeground(new java.awt.Color(204, 0, 0));
        montoSubcontratadoPorMes.setText("0.0");

        gananciasPorMes.setFont(new java.awt.Font("Tahoma", 1, 12));
        gananciasPorMes.setForeground(new java.awt.Color(153, 153, 153));
        gananciasPorMes.setText("0.0");

        perdidasPorMes.setFont(new java.awt.Font("Tahoma", 1, 12));
        perdidasPorMes.setForeground(new java.awt.Color(153, 153, 153));
        perdidasPorMes.setText("0.0");

        jLabel125.setText("-    Pago de nómina Bs.F.:");

        gastoNomina.setForeground(new java.awt.Color(204, 0, 0));
        gastoNomina.setText("0.0");

        jLabel126.setText("GASTOS:");

        jLabel128.setText("-    Otros gastos Bs.F.:");

        otrosGastos.setForeground(new java.awt.Color(204, 0, 0));
        otrosGastos.setText("0.0");

        org.jdesktop.layout.GroupLayout jPanel30Layout = new org.jdesktop.layout.GroupLayout(jPanel30);
        jPanel30.setLayout(jPanel30Layout);
        jPanel30Layout.setHorizontalGroup(
            jPanel30Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel30Layout.createSequentialGroup()
                .addContainerGap()
                .add(jPanel30Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(jPanel30Layout.createSequentialGroup()
                        .add(jLabel95)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED, 157, Short.MAX_VALUE)
                        .add(montoCotizadoPorMes))
                    .add(jPanel30Layout.createSequentialGroup()
                        .add(jLabel97)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED, 111, Short.MAX_VALUE)
                        .add(montoSubcontratadoPorMes))
                    .add(jLabel126)
                    .add(org.jdesktop.layout.GroupLayout.TRAILING, jPanel30Layout.createSequentialGroup()
                        .add(jLabel125)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED, 163, Short.MAX_VALUE)
                        .add(gastoNomina))
                    .add(jPanel30Layout.createSequentialGroup()
                        .add(jLabel128)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED, 177, Short.MAX_VALUE)
                        .add(otrosGastos))
                    .add(jPanel30Layout.createSequentialGroup()
                        .add(jLabel102)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED, 139, Short.MAX_VALUE)
                        .add(gananciasPorMes))
                    .add(org.jdesktop.layout.GroupLayout.TRAILING, jPanel30Layout.createSequentialGroup()
                        .add(jLabel105)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED, 148, Short.MAX_VALUE)
                        .add(perdidasPorMes)))
                .addContainerGap())
        );
        jPanel30Layout.setVerticalGroup(
            jPanel30Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel30Layout.createSequentialGroup()
                .add(jPanel30Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(jLabel95)
                    .add(montoCotizadoPorMes))
                .add(18, 18, 18)
                .add(jLabel126)
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                .add(jPanel30Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(jLabel97)
                    .add(montoSubcontratadoPorMes))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                .add(jPanel30Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(jLabel125)
                    .add(gastoNomina))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                .add(jPanel30Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(jLabel128)
                    .add(otrosGastos))
                .add(18, 18, 18)
                .add(jPanel30Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(jLabel102)
                    .add(gananciasPorMes))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                .add(jPanel30Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(jLabel105)
                    .add(perdidasPorMes))
                .addContainerGap(org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );

        monthChooser.setMonth(0);
        monthChooser.setYearChooser(null);

        jLabel109.setFont(new java.awt.Font("Script MT Bold", 2, 16));
        jLabel109.setText("Festejos y Decoraciones MDJ");

        jLabel110.setIcon(new javax.swing.ImageIcon(getClass().getResource("/Iconos/estadisticas.PNG"))); // NOI18N

        jLabel111.setFont(new java.awt.Font("Script MT Bold", 2, 16));
        jLabel111.setText("Estado financiero por mes de");

        jLabel112.setText("-    Cantidad total eventos:");

        cantidadEventosMes.setText("0");

        org.jdesktop.layout.GroupLayout jPanel34Layout = new org.jdesktop.layout.GroupLayout(jPanel34);
        jPanel34.setLayout(jPanel34Layout);
        jPanel34Layout.setHorizontalGroup(
            jPanel34Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel34Layout.createSequentialGroup()
                .addContainerGap()
                .add(jPanel34Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(jPanel34Layout.createSequentialGroup()
                        .add(jPanel32, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                        .addContainerGap())
                    .add(jPanel34Layout.createSequentialGroup()
                        .add(jPanel34Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                            .add(jPanel34Layout.createSequentialGroup()
                                .add(jLabel110)
                                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                                .add(jPanel34Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                                    .add(jLabel111, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 262, Short.MAX_VALUE)
                                    .add(jLabel109, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 262, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)))
                            .add(jPanel30, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                        .add(jPanel34Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                            .add(jPanel34Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                                .add(jPanel34Layout.createSequentialGroup()
                                    .add(jLabel104, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                                    .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                                    .add(monthChooser, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                                    .add(18, 18, 18)
                                    .add(consultarEstadistica)
                                    .add(87, 87, 87))
                                .add(jPanel34Layout.createSequentialGroup()
                                    .add(jLabel112)
                                    .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                                    .add(cantidadEventosMes)
                                    .addContainerGap()))
                            .add(jPanel34Layout.createSequentialGroup()
                                .add(jPanel31, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 393, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                                .addContainerGap())))))
        );
        jPanel34Layout.setVerticalGroup(
            jPanel34Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel34Layout.createSequentialGroup()
                .addContainerGap()
                .add(jPanel34Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING)
                    .add(jPanel34Layout.createSequentialGroup()
                        .add(jPanel34Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING)
                            .add(jLabel110)
                            .add(jPanel34Layout.createSequentialGroup()
                                .add(jLabel111)
                                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                                .add(jLabel109)
                                .add(3, 3, 3)))
                        .add(40, 40, 40))
                    .add(jPanel34Layout.createSequentialGroup()
                        .add(jPanel34Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING)
                            .add(jLabel104)
                            .add(consultarEstadistica, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 23, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                            .add(monthChooser, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
                        .add(13, 13, 13)
                        .add(jPanel34Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                            .add(jLabel112)
                            .add(cantidadEventosMes))
                        .add(11, 11, 11)))
                .add(jPanel34Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING, false)
                    .add(jPanel31, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .add(jPanel30, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                .add(jPanel32, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                .addContainerGap(57, Short.MAX_VALUE))
        );

        org.jdesktop.layout.GroupLayout jPanel27Layout = new org.jdesktop.layout.GroupLayout(jPanel27);
        jPanel27.setLayout(jPanel27Layout);
        jPanel27Layout.setHorizontalGroup(
            jPanel27Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(org.jdesktop.layout.GroupLayout.TRAILING, jPanel27Layout.createSequentialGroup()
                .addContainerGap(46, Short.MAX_VALUE)
                .add(jPanel34, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 780, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                .add(35, 35, 35))
        );
        jPanel27Layout.setVerticalGroup(
            jPanel27Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(jPanel27Layout.createSequentialGroup()
                .addContainerGap()
                .add(jPanel34, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 602, Short.MAX_VALUE)
                .addContainerGap())
        );

        jTabbedPane1.addTab("Estado Financiero Mensual", jPanel27);

        salir.setIcon(new javax.swing.ImageIcon(getClass().getResource("/Iconos/exit.png"))); // NOI18N
        salir.setText("Salir");
        salir.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                salirActionPerformed(evt);
            }
        });

        archivo.setText("Archivo");

        nuevaCotizacion.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_C, java.awt.event.InputEvent.CTRL_MASK));
        nuevaCotizacion.setIcon(new javax.swing.ImageIcon(getClass().getResource("/Iconos/add.png"))); // NOI18N
        nuevaCotizacion.setText("Nueva Cotizacion...");
        nuevaCotizacion.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                nuevaCotizacionActionPerformed(evt);
            }
        });
        archivo.add(nuevaCotizacion);

        informacionSistema.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_S, java.awt.event.InputEvent.CTRL_MASK));
        informacionSistema.setIcon(new javax.swing.ImageIcon(getClass().getResource("/Iconos/database.png"))); // NOI18N
        informacionSistema.setText("Informacion del Sistema...");
        informacionSistema.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                informacionSistemaActionPerformed(evt);
            }
        });
        archivo.add(informacionSistema);

        jMenuItem2.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_P, java.awt.event.InputEvent.CTRL_MASK));
        jMenuItem2.setIcon(new javax.swing.ImageIcon(getClass().getResource("/Iconos/money.png"))); // NOI18N
        jMenuItem2.setText("Cancelacion de Eventos");
        jMenuItem2.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jMenuItem2ActionPerformed(evt);
            }
        });
        archivo.add(jMenuItem2);
        archivo.add(jSeparator1);

        exit.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_E, java.awt.event.InputEvent.CTRL_MASK));
        exit.setIcon(new javax.swing.ImageIcon(getClass().getResource("/Iconos/exit.png"))); // NOI18N
        exit.setText("Salir");
        exit.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                exitActionPerformed(evt);
            }
        });
        archivo.add(exit);

        jMenuBar1.add(archivo);

        jMenu1.setText("Ayuda");

        acercaDe.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_A, java.awt.event.InputEvent.CTRL_MASK));
        acercaDe.setIcon(new javax.swing.ImageIcon(getClass().getResource("/Iconos/info.png"))); // NOI18N
        acercaDe.setText("Acerca de MDJ");
        acercaDe.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                acercaDeActionPerformed(evt);
            }
        });
        jMenu1.add(acercaDe);

        jMenuBar1.add(jMenu1);

        setJMenuBar(jMenuBar1);

        org.jdesktop.layout.GroupLayout layout = new org.jdesktop.layout.GroupLayout(getContentPane());
        getContentPane().setLayout(layout);
        layout.setHorizontalGroup(
            layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(layout.createSequentialGroup()
                .addContainerGap()
                .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING)
                    .add(salir)
                    .add(jTabbedPane1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
                .addContainerGap(15, Short.MAX_VALUE))
        );
        layout.setVerticalGroup(
            layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(layout.createSequentialGroup()
                .addContainerGap()
                .add(jTabbedPane1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 652, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                .add(salir)
                .addContainerGap(org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );

        bindingGroup.bind();

        pack();
    }// </editor-fold>//GEN-END:initComponents

    private void nuevaCotizacionActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_nuevaCotizacionActionPerformed
        NuevaCotizacion cot;
        try {
            cot = new NuevaCotizacion();
            cot.setVisible(true);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }

}//GEN-LAST:event_nuevaCotizacionActionPerformed

    private void informacionSistemaActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_informacionSistemaActionPerformed
        InformacionSistema2 info = new InformacionSistema2();
        info.setVisible(true);
}//GEN-LAST:event_informacionSistemaActionPerformed

    private void exitActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_exitActionPerformed
        int resultado = JOptionPane.showConfirmDialog(null, "Esta seguro que desea realizar esta operacion?", "ATENCION", JOptionPane.OK_CANCEL_OPTION);
        if (resultado == 0) {
            System.exit(0);
        }
}//GEN-LAST:event_exitActionPerformed

    private void salirActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_salirActionPerformed
        int resultado = JOptionPane.showConfirmDialog(null, "Esta seguro que desea salir del sistema?", "ATENCION", JOptionPane.OK_CANCEL_OPTION);
        if (resultado == 0) {
            System.exit(0);
        }
}//GEN-LAST:event_salirActionPerformed

    private void acercaDeActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_acercaDeActionPerformed
        About ab = new About();
        ab.setVisible(true);
    }//GEN-LAST:event_acercaDeActionPerformed

    private double aumentoMontoSegundaCuotaEventosSinPagar(Integer id, double montoTotal) {
        try {
            controlEvento = new ControlEvento();
            List<Evento> eventos = controlEvento.consultarEventosSinPagar();
            controlCotizacion = new ControlCotizacion();
            List<Cotizacion> cotizaciones = controlCotizacion.consultarCotizaciones();
            for (int j = 0; j < eventos.size(); j++) {
                if (eventos.get(j).getIdEvento().equals(id)) {
                    for (int k = 0; k < cotizaciones.size(); k++) {
                        if (eventos.get(j).getIdEvento().equals(cotizaciones.get(k).getEventoIdEvento())) {
                            java.sql.Date FechaEvento = new java.sql.Date(eventos.get(j).getFecha().getTime());
                            java.sql.Date FechaCotizacion = new java.sql.Date(cotizaciones.get(k).getFecha().getTime());
                            long diff = FechaEvento.getTime() - FechaCotizacion.getTime();
                            long dias = 0;
                            if (FechaEvento.equals(FechaCotizacion)) {
                                dias = 0;
                            } else {
                                dias = (diff / (1000 * 60 * 60 * 24)) + 1;
                            }
                            if (dias >= 30) {
                                double porcentaje = montoTotal * 0.01;
                                double montoRedondear = montoTotal + porcentaje;
                                montoTotal = this.redondear(montoRedondear, 2);
                            }
                        }
                    }
                }
            }

        } catch (IOException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }
        return montoTotal;
    }

    private double aumentoMontoSegundaCuotaEventosSinCuotas(Integer id, double montoTotal) {
        try {
            controlEvento = new ControlEvento();
            List<Evento> eventosSinCuotas = controlEvento.consultarEventosSinCuotas();
            controlCotizacion = new ControlCotizacion();
            List<Cotizacion> cotizaciones = controlCotizacion.consultarCotizaciones();
            for (int j = 0; j < eventosSinCuotas.size(); j++) {
                if (eventosSinCuotas.get(j).getIdEvento().equals(id)) {
                    for (int k = 0; k < cotizaciones.size(); k++) {
                        if (eventosSinCuotas.get(j).getIdEvento().equals(cotizaciones.get(k).getEventoIdEvento())) {
                            java.sql.Date FechaEvento = new java.sql.Date(eventosSinCuotas.get(j).getFecha().getTime());
                            java.sql.Date FechaCotizacion = new java.sql.Date(cotizaciones.get(k).getFecha().getTime());
                            long diff = FechaEvento.getTime() - FechaCotizacion.getTime();
                            long dias = 0;
                            if (FechaEvento.equals(FechaCotizacion)) {
                                dias = 0;
                            } else {
                                dias = (diff / (1000 * 60 * 60 * 24)) + 1;
                            }
                            if (dias >= 30) {
                                double porcentaje = montoTotal * 0.01;
                                double montoRedondear = montoTotal + porcentaje;
                                montoTotal = this.redondear(montoRedondear, 2);
                            }
                        }
                    }
                }
            }

        } catch (IOException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }
        return montoTotal;
    }

    private void jMenuItem2ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jMenuItem2ActionPerformed
        cancelacionEvento ce = new cancelacionEvento();
        ce.setVisible(true);
}//GEN-LAST:event_jMenuItem2ActionPerformed

    private void jcbProveedoresCuadreActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jcbProveedoresCuadreActionPerformed
        try {
            controlProveedor = new ControlProveedor();
            List<Proveedor> proveedores = controlProveedor.consultarProveedorRecibo();
            this.cargarTablaInsumosSubcontratadosCuadre(proveedores);
            this.calcularMontoTotalCuadre();
            this.calcularMontoTotalSubcontratadoCuadre();
        } catch (IOException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }
}//GEN-LAST:event_jcbProveedoresCuadreActionPerformed

    private void mostrarCuadreGananciaActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_mostrarCuadreGananciaActionPerformed
        this.cargarIdEventosCuadre();
}//GEN-LAST:event_mostrarCuadreGananciaActionPerformed

    private void idEventosCuadreActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_idEventosCuadreActionPerformed
        try {
            controlEmpleado = new ControlEmpleado();
            controlEvento = new ControlEvento();
            List<Evento> eventos = controlEvento.consultarEventosSegundaCuota();
            if (eventos.size() > 0) {
                this.asignarLabelEventosCuadre(eventos);
                this.asignarLabelClienteCuadre(eventos);
                this.asignarLabelGastoContratados(eventos);
                this.cargarJcbProveedoresCuadre();
                this.cargarTablaFacturaCuadre(eventos);
                this.calcularSubTotalCuadre();
                this.calcularIvaCuadre();
                this.calcularDepositoCuadre();
                this.calcularTotalCuadre();
                this.calcularTotalGanancias();
            } else {
                if (eventos.size() < 0) {
                    JOptionPane.showMessageDialog(aviso, "No existen eventos para hacer el cuadre", "Warning", 1);
                }
            }

        } catch (IOException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }
}//GEN-LAST:event_idEventosCuadreActionPerformed

    private void tablaEstadisticasMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_tablaEstadisticasMouseClicked
        Integer rowSelectedTabla = 0;
        Integer idEventoSeleccionado = 0;
        rowSelectedTabla = tablaEstadisticas.getSelectedRow();
        idEventoSeleccionado = Integer.parseInt(tablaEstadisticas.getValueAt(rowSelectedTabla, 0).toString());
        try {
            controlCotizacion = new ControlCotizacion();
            List<Cotizacion> cotizaciones = controlCotizacion.consultarFechaCotizaciones();

            controlClienteCompania = new ControlClienteCompania();
            List<ClienteCompania> companias = controlClienteCompania.consultarClienteCompaniaSegundaCuota();

            controlClienteParticular = new ControlClienteParticular();
            List<ClienteParticular> particular = controlClienteParticular.consultarClienteParticularSegundaCuota();

            controlEmpleado = new ControlEmpleado();
            List<Empleado> ejecutivos = controlEmpleado.consultarEjecutivosEncargado();

            controlEvento = new ControlEvento();
            List<Evento> eventoEjecutivo = controlEvento.consultarEventosEjecutivo();

            for (int j = 0; j < cotizaciones.size(); j++) {
                if (idEventoSeleccionado.equals(cotizaciones.get(j).getEventoIdEvento())) {
                    if (cotizaciones.get(j).getClienteCompaniaRif().equals("")) {
                        //rifEstadistica.setText("--");
                    } else {
                        ciEstadistica.setText(cotizaciones.get(j).getClienteCompaniaRif());

                        for (int z = 0; z < companias.size(); z++) {
                            if (cotizaciones.get(j).getClienteCompaniaRif().equals(companias.get(z).getRif())) {
                                nombreClienteEstadistica.setText(companias.get(z).getNombre());
                                telefonoEstadistica.setText(companias.get(z).getTelefono());
                            }
                        }
                    }
                    if (cotizaciones.get(j).getClienteParticularCedula().equals(0)) {
                        //ciEstadistica.setText("--");
                    } else {
                        ciEstadistica.setText(cotizaciones.get(j).getClienteParticularCedula().toString());

                        for (int z = 0; z < particular.size(); z++) {
                            if (cotizaciones.get(j).getClienteParticularCedula().equals(particular.get(z).getCedula())) {
                                nombreClienteEstadistica.setText(particular.get(z).getNombre() + " " + particular.get(z).getApellido());
                                telefonoEstadistica.setText(particular.get(z).getTelefono());
                            }
                        }
                    }
                }
            }
            for (int z = 0; z < eventoEjecutivo.size(); z++) {
                if (eventoEjecutivo.get(z).getIdEvento().equals(idEventoSeleccionado)) {
                    horaInicioEstadistica.setText(eventoEjecutivo.get(z).getHoraInicio().toString());
                    horaFinEstadistica.setText(eventoEjecutivo.get(z).getHoraFin().toString());
                    fechaEventoEstadistica.setText(eventoEjecutivo.get(z).getFecha().toString());
                    for (int j = 0; j < ejecutivos.size(); j++) {
                        if (eventoEjecutivo.get(z).getEjecutivoCedula().equals(ejecutivos.get(j).getCedula())) {
                            ejecutivoEncargadoEstadistica.setText(ejecutivos.get(j).getNombre() + " " + ejecutivos.get(j).getApellido());
                        }
                    }
                }
            }
        } catch (IOException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }
}//GEN-LAST:event_tablaEstadisticasMouseClicked

    private void consultarEstadisticaActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_consultarEstadisticaActionPerformed
        gananciasPorMes.setForeground(Color.GRAY);
        perdidasPorMes.setForeground(Color.GRAY);
        gananciasPorMes.setText("0.0");
        perdidasPorMes.setText("0.0");
        montoCotizadoPorMes.setText("0.0");
        montoSubcontratadoPorMes.setText("0.0");
        gastoNomina.setText("0.0");
        otrosGastos.setText("0.0");
        cantidadEventosMes.setText("0");
        nombreClienteEstadistica.setText("Nombre Cliente");
        ciEstadistica.setText("--");
        horaInicioEstadistica.setText("00:00");
        horaFinEstadistica.setText("00:00");
        fechaEventoEstadistica.setText("----/--/--");
        telefonoEstadistica.setText("teléfono");
        ejecutivoEncargadoEstadistica.setText("Ejecutivo Encargado");
        Integer numMes = monthChooser.getMonth() + 1;
        String mes = "";
        if (numMes < 10) {
            mes = "0" + numMes.toString();
        } else {
            mes = numMes.toString();
        }
        this.cargarTablaEstadisticas(mes);
}//GEN-LAST:event_consultarEstadisticaActionPerformed

    private void jcbProveedoresReciboActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jcbProveedoresReciboActionPerformed
        try {
            controlProveedor = new ControlProveedor();
            List<Proveedor> proveedores = controlProveedor.consultarProveedorRecibo();
            if (jcbProveedoresRecibo.getItemCount() != 0) {
                String idTmp[] = jcbProveedoresRecibo.getSelectedItem().toString().split(", ");
                Integer idProveedor = Integer.parseInt(idTmp[0]);

                for (int i = 0; i < proveedores.size(); i++) {
                    if (proveedores.get(i).getIdProveedor().equals(idProveedor)) {
                        direccionProveedorRecibo.setText(proveedores.get(i).getDireccion());
                        telefonoProveedorRecibo.setText(proveedores.get(i).getTelefono());
                    }
                }
            }
            this.cargarTablaInsumosSubcontratados(proveedores);
            this.calcularMontoTotalRecibo();
            this.calcularMontoTotalSubcontratado();
        } catch (IOException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }
}//GEN-LAST:event_jcbProveedoresReciboActionPerformed

    private void jcbInsumosSubcontratadosActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jcbInsumosSubcontratadosActionPerformed
        jcbProveedoresRecibo.removeAllItems();
        try {
            Integer idEvento = 0;
            Integer id = 0;
            String concepto = null;
            String id2 = null;
            String concepto2 = null;
            String comparacion = null;
            String comparacionNueva = null;
            controlEvento = new ControlEvento();
            List<Evento> eventos = controlEvento.consultarEventosRecibo();
            if (jcbInsumosSubcontratados.getItemCount() != 0) {
                String[] idTmp = jcbInsumosSubcontratados.getSelectedItem().toString().split(", ");
                idEvento = Integer.parseInt(idTmp[0]);
                for (int i = 0; i < eventos.size(); i++) {
                    if (eventos.get(i).getIdEvento().equals(idEvento)) {
                        fechaInsumoSubcontratados.setText(eventos.get(i).getFecha().toString());
                        horaInicioEventosInsumoSubcontratado.setText(eventos.get(i).getHoraInicio().toString());
                        horaFinEventosInsumoSubcontratado.setText(eventos.get(i).getHoraFin().toString());
                    }
                }
                jcbProveedoresRecibo.setVisible(false);
                if (jcbProveedoresRecibo.isPopupVisible() != true) {
                    jcbProveedoresRecibo.removeAllItems();
                }
                controlOrdenCompra = new ControlOrdenCompra();
                List<OrdenCompra> ordenes = controlOrdenCompra.consultarOrdenCompraProveedor();

                controlProveedor = new ControlProveedor();
                List<Proveedor> proveedores = controlProveedor.consultarProveedorProveedor();

                for (OrdenCompra o : ordenes) {
                    boolean flag = true;
                    for (Proveedor p : proveedores) {
                        if ((p.getIdProveedor().equals(o.getProveedorIdProveedor())) && flag && (o.getCotizacionEventoIdEvento().equals(idEvento))) {
                            id = p.getIdProveedor();
                            concepto = p.getNombre();
                            comparacionNueva = id + ", " + concepto;
                            if (jcbProveedoresRecibo.getItemCount() == 0) {
                                jcbProveedoresRecibo.addItem(id + ", " + concepto);
                                id2 = id.toString();
                                concepto2 = concepto;
                                comparacion = id2 + ", " + concepto2;
                            }
                            if (jcbProveedoresRecibo.getItemCount() != 0) {
                                if (!comparacion.equals(comparacionNueva)) {
                                    jcbProveedoresRecibo.addItem(id + ", " + concepto);
                                    id2 = id.toString();
                                    concepto2 = concepto;
                                    comparacion = id2 + ", " + concepto2;
                                }
                            }
                            flag = false;
                        }
                    }
                }
                jcbProveedoresRecibo.setVisible(true);
            }
        } catch (IOException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }
}//GEN-LAST:event_jcbInsumosSubcontratadosActionPerformed

    private void mostrarReciboPagoActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_mostrarReciboPagoActionPerformed
        try {
            controlEvento = new ControlEvento();
            List<Evento> eventos = controlEvento.consultarEventosRecibo();
            this.cargarjcbInsumosSubcontratados(eventos);
        } catch (IOException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }
}//GEN-LAST:event_mostrarReciboPagoActionPerformed

    private void limpiar12ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_limpiar12ActionPerformed
        // TODO add your handling code here:
}//GEN-LAST:event_limpiar12ActionPerformed

    private void limpiar11ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_limpiar11ActionPerformed
        // TODO add your handling code here:
}//GEN-LAST:event_limpiar11ActionPerformed

    private void nombreBanco1ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_nombreBanco1ActionPerformed
        // TODO add your handling code here:
}//GEN-LAST:event_nombreBanco1ActionPerformed

    private void tipoPagoCombo1ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_tipoPagoCombo1ActionPerformed
        if (tipoPagoCombo1.getSelectedItem().toString().equals("Cheque")) {
            tipoCtaCombo1.setEnabled(false);
            tipoTarjetaCombo1.setEnabled(false);
            nombreBanco1.setEnabled(false);
            numeroTarjeta1.setEnabled(false);
            codigoSeguridad1.setEnabled(false);
            nombreBancoCheque1.setEnabled(true);
            numeroCheque1.setEnabled(true);
        }
        if (tipoPagoCombo1.getSelectedItem().toString().equals("Efectivo")) {
            tipoCtaCombo1.setEnabled(false);
            tipoTarjetaCombo1.setEnabled(false);
            nombreBanco1.setEnabled(false);
            numeroTarjeta1.setEnabled(false);
            codigoSeguridad1.setEnabled(false);
            nombreBancoCheque1.setEnabled(false);
            numeroCheque1.setEnabled(false);
        }
        if (tipoPagoCombo1.getSelectedItem().toString().equals("Tarjeta")) {
            tipoTarjetaCombo1.setEnabled(true);
            nombreBanco1.setEnabled(true);
            numeroTarjeta1.setEnabled(true);
            codigoSeguridad1.setEnabled(true);
            nombreBancoCheque1.setEnabled(false);
            numeroCheque1.setEnabled(false);

            tipoTarjetaCombo1.addActionListener(new ActionListener() {

                public void actionPerformed(ActionEvent evt) {
                    if (tipoTarjetaCombo1.getSelectedItem().toString().equals("Crédito")) {
                        tipoCtaCombo1.setEnabled(false);
                        tipoTarjetaCombo1.setEnabled(true);
                        nombreBanco1.setEnabled(true);
                        numeroTarjeta1.setEnabled(true);
                        codigoSeguridad1.setEnabled(true);
                        nombreBancoCheque1.setEnabled(false);
                        numeroCheque1.setEnabled(false);
                    }
                    if (tipoTarjetaCombo1.getSelectedItem().toString().equals("Débito")) {
                        tipoCtaCombo1.setEnabled(true);
                        tipoTarjetaCombo1.setEnabled(true);
                        nombreBanco1.setEnabled(true);
                        numeroTarjeta1.setEnabled(true);
                        codigoSeguridad1.setEnabled(true);
                        nombreBancoCheque1.setEnabled(false);
                        numeroCheque1.setEnabled(false);
                    }
                }
            });

        }
}//GEN-LAST:event_tipoPagoCombo1ActionPerformed

    private void insertarOrdenCompraActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_insertarOrdenCompraActionPerformed
        try {
            controlEvento = new ControlEvento();
            List<Evento> eventos = controlEvento.consultarEventosInsumosSubcontratar();
            controlCotizacion = new ControlCotizacion();
            List<Cotizacion> cotizaciones = controlCotizacion.consultarCotizacionesInsumosSubcontratar();
            controlProveedor = new ControlProveedor();
            List<Proveedor> proveedores = controlProveedor.consultarProveedor();
            controlOrdenCompra = new ControlOrdenCompra();
            controlProveedor = new ControlProveedor();
            controlInsumo = new ControlInsumo();
            controlInsumoInventario = new ControlInsumoInventario();
            controlRecibo = new ControlRecibo();
            controlPago = new ControlPago();

            Integer id = 0;
            Integer rowSelectedInsumo = 0;
            Integer idInsumo = 0;

            Integer rowSelectedProveedor = 0;
            Integer idProveedor = 0;
            String concepto = null;
            boolean result = false;

            if (jcbEventosInsumosASubcontratar.getItemCount() != 0) {
                String idTmp[] = jcbEventosInsumosASubcontratar.getSelectedItem().toString().split(", ");
                id = Integer.parseInt(idTmp[0]);

                for (int i = 0; i < eventos.size(); i++) {
                    if (eventos.get(i).getIdEvento().equals(id)) {
                        for (int j = 0; j < cotizaciones.size(); j++) {
                            if (eventos.get(i).getIdEvento().equals(cotizaciones.get(j).getEventoIdEvento())) {
                                Integer idCotizacion = 0;
                                Integer idEvento = 0;
                                idEvento = eventos.get(i).getIdEvento();
                                idCotizacion = cotizaciones.get(j).getEventoIdEvento();
                                double montoTotal = Double.parseDouble(totalPagoPorInsumo.getText());

                                if (tablaInsumosASubcontratar.getSelectedRow() == -1 || tablaProveedor.getSelectedRow() == -1) {
                                    result = false;
                                    JOptionPane.showMessageDialog(aviso, "Debe seleccionar el proveedor y el insumo a subcontratar", "Warning", 1);
                                } else {
                                    rowSelectedProveedor = tablaProveedor.getSelectedRow();
                                    idProveedor = Integer.parseInt(tablaProveedor.getValueAt(rowSelectedProveedor, 0).toString());

                                    rowSelectedInsumo = tablaInsumosASubcontratar.getSelectedRow();
                                    idInsumo = Integer.parseInt(tablaInsumosASubcontratar.getValueAt(rowSelectedInsumo, 0).toString());
                                    concepto = tablaInsumosASubcontratar.getValueAt(rowSelectedInsumo, 1).toString();
                                    Integer cant = 0;
                                    cant = Integer.parseInt(tablaInsumosASubcontratar.getValueAt(rowSelectedInsumo, 2).toString());

                                    OrdenCompra orden = new OrdenCompra(cant, montoTotal, idProveedor, idCotizacion, idEvento, idInsumo);
                                    result = controlOrdenCompra.agregarOrdenCompra(orden);

                                    if (tipoPagoCombo1.getSelectedItem().toString().equals("Cheque")) {

                                        if ((nombreBancoCheque1.getText().equals("")) || (numeroCheque1.getText().equals(""))) {
                                            JOptionPane.showMessageDialog(aviso, "Debe llenar todos los campos de Cheque", "Warning", 1);
                                        } else {
                                            String numCheque = numeroCheque1.getText();
                                            String bancoCheque = nombreBancoCheque1.getText();
                                            String tipoPago = tipoPagoCombo1.getSelectedItem().toString();
                                            String tipoTarjeta = "";
                                            String numTarjeta = "";
                                            String codSeguridad = "";
                                            String bankTarjeta = "";
                                            String tipoCtaDebito = "";
                                            Integer cotizaIdCotiza = eventos.get(i).getIdEvento();
                                            Integer cotizaEventoIdEvento = eventos.get(i).getIdEvento();
                                            java.text.SimpleDateFormat fmt = new java.text.SimpleDateFormat("yyyy-MM-dd");
                                            java.sql.Date now = new java.sql.Date(System.currentTimeMillis());

                                            Date fechaActual = Date.valueOf(fmt.format(now));

                                            List<OrdenCompra> ultimaOrden = controlOrdenCompra.consultarOrdenCompra();
                                            Integer UltimaOrden = ultimaOrden.get(ultimaOrden.size() - 1).getIdOrden();

                                            Recibo recibo = new Recibo(montoTotal, concepto, fechaActual, UltimaOrden, idProveedor, idCotizacion, idEvento, idInsumo);
                                            controlRecibo.agregarRecibo(recibo);

                                            List<Recibo> ultimoRecibo = controlRecibo.consultarRecibo();
                                            Integer UltimoRecibo = ultimoRecibo.get(ultimoRecibo.size() - 1).getIdRecibo();

                                            Pago pago = new Pago(montoTotal, tipoPago, tipoTarjeta, numCheque, bancoCheque, numTarjeta, codSeguridad, bankTarjeta, tipoCtaDebito, cotizaIdCotiza, cotizaEventoIdEvento, null, UltimoRecibo);
                                            controlPago.agregarPago(pago);

                                        }//FINAL DEL ELSE DE SI LLENO LOS DATOS DEL CHEQUE
                                    }
                                    if (tipoPagoCombo1.getSelectedItem().toString().equals("Tarjeta")) {
                                        if ((nombreBanco1.getText().equals("")) || (numeroTarjeta1.getText().equals("")) || (codigoSeguridad1.getText().equals(""))) {
                                            JOptionPane.showMessageDialog(aviso, "Debe llenar todos los campos de Tarjeta", "Warning", 1);
                                        } else {
                                            String tipoTarjeta = tipoTarjetaCombo1.getSelectedItem().toString();
                                            if (tipoTarjeta.equals("Crédito")) {
                                                String tipoPago = tipoPagoCombo1.getSelectedItem().toString();
                                                String nomBanco = nombreBanco1.getText();
                                                String numTarjeta = numeroTarjeta1.getText();
                                                String codSeguridad = codigoSeguridad1.getText();
                                                String tipoCtaDebito = "";
                                                Integer cotizaIdCotiza = eventos.get(i).getIdEvento();
                                                Integer cotizaEventoIdEvento = eventos.get(i).getIdEvento();
                                                String bancoCheque = "";
                                                String numCheque = "";

                                                java.text.SimpleDateFormat fmt = new java.text.SimpleDateFormat("yyyy-MM-dd");
                                                java.sql.Date now = new java.sql.Date(System.currentTimeMillis());

                                                Date fechaActual = Date.valueOf(fmt.format(now));

                                                List<OrdenCompra> ultimaOrden = controlOrdenCompra.consultarOrdenCompra();
                                                Integer UltimaOrden = ultimaOrden.get(ultimaOrden.size() - 1).getIdOrden();

                                                Recibo recibo = new Recibo(montoTotal, concepto, fechaActual, UltimaOrden, idProveedor, idCotizacion, idEvento, idInsumo);
                                                controlRecibo.agregarRecibo(recibo);

                                                List<Recibo> ultimoRecibo = controlRecibo.consultarRecibo();
                                                Integer UltimoRecibo = ultimoRecibo.get(ultimoRecibo.size() - 1).getIdRecibo();

                                                Pago pago = new Pago(montoTotal, tipoPago, tipoTarjeta, numCheque, bancoCheque, numTarjeta, codSeguridad, nomBanco, tipoCtaDebito, cotizaIdCotiza, cotizaEventoIdEvento, null, UltimoRecibo);
                                                controlPago.agregarPago(pago);

                                            } else {
                                                String tipoTarjetaDebito = tipoTarjetaCombo1.getSelectedItem().toString();
                                                if (tipoTarjetaDebito.equals("Débito")) {
                                                    String tipoPago = tipoPagoCombo1.getSelectedItem().toString();
                                                    String nomBanco = nombreBanco1.getText();
                                                    String numTarjeta = numeroTarjeta1.getText();
                                                    String codSeguridad = codigoSeguridad1.getText();
                                                    String tipoCtaDebito = tipoCtaCombo1.getSelectedItem().toString();
                                                    Integer cotizaIdCotiza = eventos.get(i).getIdEvento();
                                                    Integer cotizaEventoIdEvento = eventos.get(i).getIdEvento();
                                                    String bancoCheque = "";
                                                    String numCheque = "";

                                                    java.text.SimpleDateFormat fmt = new java.text.SimpleDateFormat("yyyy-MM-dd");
                                                    java.sql.Date now = new java.sql.Date(System.currentTimeMillis());

                                                    Date fechaActual = Date.valueOf(fmt.format(now));

                                                    List<OrdenCompra> ultimaOrden = controlOrdenCompra.consultarOrdenCompra();
                                                    Integer UltimaOrden = ultimaOrden.get(ultimaOrden.size() - 1).getIdOrden();

                                                    Recibo recibo = new Recibo(montoTotal, concepto, fechaActual, UltimaOrden, idProveedor, idCotizacion, idEvento, idInsumo);
                                                    controlRecibo.agregarRecibo(recibo);

                                                    List<Recibo> ultimoRecibo = controlRecibo.consultarRecibo();
                                                    Integer UltimoRecibo = ultimoRecibo.get(ultimoRecibo.size() - 1).getIdRecibo();

                                                    Pago pago = new Pago(montoTotal, tipoPago, tipoTarjeta, numCheque, bancoCheque, numTarjeta, codSeguridad, nomBanco, tipoCtaDebito, cotizaIdCotiza, cotizaEventoIdEvento, null, UltimoRecibo);
                                                    controlPago.agregarPago(pago);
                                                }//FIN DEL IF DE LA CONDICION DE DEBITO
                                            }
                                        }//FINAL DEL ELSE DE TIPO DE TARJETA
                                    } else {//FINAL TARJETA
                                        if (tipoPagoCombo1.getSelectedItem().toString().equals("Efectivo")) {
                                            String numCheque = "";
                                            String bancoCheque = "";
                                            String tipoPago = tipoPagoCombo1.getSelectedItem().toString();
                                            String tipoTarjeta = "";
                                            String numTarjeta = "";
                                            String codSeguridad = "";
                                            String bankTarjeta = "";
                                            String tipoCtaDebito = "";
                                            Integer cotizaIdCotiza = eventos.get(i).getIdEvento();
                                            Integer cotizaEventoIdEvento = eventos.get(i).getIdEvento();

                                            java.text.SimpleDateFormat fmt = new java.text.SimpleDateFormat("yyyy-MM-dd");
                                            java.sql.Date now = new java.sql.Date(System.currentTimeMillis());

                                            Date fechaActual = Date.valueOf(fmt.format(now));

                                            List<OrdenCompra> ultimaOrden = controlOrdenCompra.consultarOrdenCompra();
                                            Integer UltimaOrden = ultimaOrden.get(ultimaOrden.size() - 1).getIdOrden();

                                            Recibo recibo = new Recibo(montoTotal, concepto, fechaActual, UltimaOrden, idProveedor, idCotizacion, idEvento, idInsumo);
                                            controlRecibo.agregarRecibo(recibo);

                                            List<Recibo> ultimoRecibo = controlRecibo.consultarRecibo();
                                            Integer UltimoRecibo = ultimoRecibo.get(ultimoRecibo.size() - 1).getIdRecibo();

                                            Pago pago = new Pago(montoTotal, tipoPago, tipoTarjeta, numCheque, bancoCheque, numTarjeta, codSeguridad, bankTarjeta, tipoCtaDebito, cotizaIdCotiza, cotizaEventoIdEvento, null, UltimoRecibo);
                                            controlPago.agregarPago(pago);
                                        }
                                    }//FIN ELSE EFECTIVO

                                    if (result) {
                                        labelCancelado1.setEnabled(true);
                                        JOptionPane.showMessageDialog(null, "La orden de compra ha sido procesada con Exito", "Resultado", JOptionPane.INFORMATION_MESSAGE);
                                        totalPagoPorInsumo.setText("0.0");
                                        nombreBancoCheque1.setText("");
                                        numeroCheque1.setText("");
                                        nombreBanco1.setText("");
                                        numeroTarjeta1.setText("");
                                        codigoSeguridad1.setText("");
                                        labelCancelado1.setEnabled(false);
                                        jcbEventosInsumosASubcontratar.removeAllItems();
                                        controlEvento = new ControlEvento();
                                        List<Evento> eventos1 = controlEvento.consultarEventosInsumosSubcontratar();
                                        this.cargarJcbEventosInsumosASubcontratar(eventos1);
                                        this.cargarTablaProveedores(proveedores);
                                        this.cargarTablaInsumosASubcontratar(eventos1);
                                    } else {
                                        JOptionPane.showMessageDialog(null, "Error: La orden de compra no pudo ser procesada", "Resultado", JOptionPane.ERROR_MESSAGE);
                                    }
                                }
                            }
                        }
                    }
                }
            }
        } catch (IOException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }
}//GEN-LAST:event_insertarOrdenCompraActionPerformed

    private void mostrarOrdenCompraActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_mostrarOrdenCompraActionPerformed
        try {
            controlEvento = new ControlEvento();
            List<Evento> eventos = controlEvento.consultarEventosInsumosSubcontratar();
            controlProveedor = new ControlProveedor();
            List<Proveedor> proveedores = controlProveedor.consultarProveedorTablaOrdenCompra();

            this.cargarJcbEventosInsumosASubcontratar(eventos);
            this.cargarTablaProveedores(proveedores);

        } catch (IOException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }
}//GEN-LAST:event_mostrarOrdenCompraActionPerformed

    private void tablaProveedorMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_tablaProveedorMouseClicked

}//GEN-LAST:event_tablaProveedorMouseClicked

    private void tablaInsumosASubcontratarKeyPressed(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_tablaInsumosASubcontratarKeyPressed
        tablaProveedor.addMouseListener(new MouseAdapter() {

            @Override
            public void mouseClicked(MouseEvent e) {
                try {
                    Integer idInsumo = Integer.parseInt(tablaInsumosASubcontratar.getValueAt(tablaInsumosASubcontratar.getSelectedRow(), 0).toString());
                    controlProveedor = new ControlProveedor();
                    List<Proveedor> proveedores = controlProveedor.consultarProveedorTablaOrdenCompra();
                    controlInsumoInventario = new ControlInsumoInventario();
                    List<InsumoInventario> insumoInventario = controlInsumoInventario.consultarInsumoInventarioASubcontratar();
                    Integer idProveedor = 0;
                    idProveedor = Integer.parseInt(tablaProveedor.getValueAt(tablaProveedor.getSelectedRow(), 0).toString());
                    for (int r = 0; r < insumoInventario.size(); r++) {
                        if (idInsumo.equals(insumoInventario.get(r).getINSUMO_idINSUMO())) {
                            double costo = insumoInventario.get(r).getCostoUnitario();
                            double porcentaje = costo * 0.01;
                            double costoUnitario = costo - porcentaje;
                            for (int i = 0; i < proveedores.size(); i++) {
                                if (idProveedor.equals(proveedores.get(i).getIdProveedor())) {
                                    double porcentajeProveedor = proveedores.get(i).getPorcentaje();
                                    double montoResta = costoUnitario * porcentajeProveedor;
                                    double monto = costoUnitario - montoResta;
                                    double montoRedondeado = Math.round(monto * Math.pow(10, 2)) / Math.pow(10, 2);
                                    costoUnitario = montoRedondeado;
                                    tablaInsumosASubcontratar.setValueAt(costoUnitario, tablaInsumosASubcontratar.getSelectedRow(), 3);
                                }
                            }
                        }
                    }
                    double costoTotal = 0.0;
                    double costoTmp = 0.0;
                    double costo = 0.0;
                    Integer cant = 0;
                    Integer rowSelectedInsumo = tablaInsumosASubcontratar.getSelectedRow();
                    cant = Integer.parseInt(tablaInsumosASubcontratar.getValueAt(rowSelectedInsumo, 2).toString());
                    costo = Double.parseDouble(tablaInsumosASubcontratar.getValueAt(rowSelectedInsumo, 3).toString());
                    costoTmp = (costo * cant);
                    costoTotal = Math.round(costoTmp * Math.pow(10, 2)) / Math.pow(10, 2);
                    totalPagoPorInsumo.setText(Double.toString(costoTotal));
                } catch (IOException ex) {
                    Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
                } catch (SQLException ex) {
                    Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
                }

            }
        });
}//GEN-LAST:event_tablaInsumosASubcontratarKeyPressed

    private void tablaInsumosASubcontratarMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_tablaInsumosASubcontratarMouseClicked
        tablaProveedor.addMouseListener(new MouseAdapter() {

            @Override
            public void mouseClicked(MouseEvent e) {
                try {
                    Integer idInsumo = Integer.parseInt(tablaInsumosASubcontratar.getValueAt(tablaInsumosASubcontratar.getSelectedRow(), 0).toString());
                    controlProveedor = new ControlProveedor();
                    List<Proveedor> proveedores = controlProveedor.consultarProveedorTablaOrdenCompra();
                    controlInsumoInventario = new ControlInsumoInventario();
                    List<InsumoInventario> insumoInventario = controlInsumoInventario.consultarInsumoInventarioASubcontratar();
                    Integer idProveedor = 0;
                    idProveedor = Integer.parseInt(tablaProveedor.getValueAt(tablaProveedor.getSelectedRow(), 0).toString());
                    for (int r = 0; r < insumoInventario.size(); r++) {
                        if (idInsumo.equals(insumoInventario.get(r).getINSUMO_idINSUMO())) {
                            double costo = insumoInventario.get(r).getCostoUnitario();
                            double porcentaje = costo * 0.01;
                            double costoUnitario = costo - porcentaje;
                            for (int i = 0; i < proveedores.size(); i++) {
                                if (idProveedor.equals(proveedores.get(i).getIdProveedor())) {
                                    double porcentajeProveedor = proveedores.get(i).getPorcentaje();
                                    double montoResta = costoUnitario * porcentajeProveedor;
                                    double monto = costoUnitario - montoResta;
                                    double montoRedondeado = Math.round(monto * Math.pow(10, 2)) / Math.pow(10, 2);
                                    costoUnitario = montoRedondeado;
                                    tablaInsumosASubcontratar.setValueAt(costoUnitario, tablaInsumosASubcontratar.getSelectedRow(), 3);
                                }
                            }
                        }
                    }
                    double costoTotal = 0.0;
                    double costoTmp = 0.0;
                    double costo = 0.0;
                    Integer cant = 0;
                    Integer rowSelectedInsumo = tablaInsumosASubcontratar.getSelectedRow();
                    cant = Integer.parseInt(tablaInsumosASubcontratar.getValueAt(rowSelectedInsumo, 2).toString());
                    costo = Double.parseDouble(tablaInsumosASubcontratar.getValueAt(rowSelectedInsumo, 3).toString());
                    costoTmp = (costo * cant);
                    costoTotal = Math.round(costoTmp * Math.pow(10, 2)) / Math.pow(10, 2);
                    totalPagoPorInsumo.setText(Double.toString(costoTotal));
                } catch (IOException ex) {
                    Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
                } catch (SQLException ex) {
                    Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
                }

            }
        });
}//GEN-LAST:event_tablaInsumosASubcontratarMouseClicked

    private void jcbEventosInsumosASubcontratarActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jcbEventosInsumosASubcontratarActionPerformed
        try {
            controlEvento = new ControlEvento();
            List<Evento> eventos = controlEvento.consultarEventosInsumosSubcontratar();
            this.asignarLabelOrdenCompra(eventos);
            this.cargarTablaInsumosASubcontratar(eventos);
        } catch (IOException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }
}//GEN-LAST:event_jcbEventosInsumosASubcontratarActionPerformed

    private void checkTelefonoActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_checkTelefonoActionPerformed
        if (checkTelefono.isSelected()) {
            nombre4.setEnabled(true);
        } else {
            nombre4.setEnabled(false);
        }
        try {
            controlProveedor = new ControlProveedor();
            List<Proveedor> proveedores = controlProveedor.consultarProveedor();
            Integer idProveedor = Integer.parseInt(tablaProveedores.getValueAt(tablaProveedores.getSelectedRow(), 0).toString());

            for (Iterator iter = proveedores.iterator(); iter.hasNext();) {
                Proveedor pro = (Proveedor) iter.next();
                if (pro.getIdProveedor().equals(idProveedor)) {
                    if (!checkTelefono.isSelected()) {
                        nombre4.setText(pro.getTelefono());
                    }
                }
            }
        } catch (IOException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }
}//GEN-LAST:event_checkTelefonoActionPerformed

    private void nombre4ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_nombre4ActionPerformed
        // TODO add your handling code here:
}//GEN-LAST:event_nombre4ActionPerformed

    private void checkDireccionActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_checkDireccionActionPerformed
        if (checkDireccion.isSelected()) {
            direccionComp3.setEnabled(true);
        } else {
            direccionComp3.setEnabled(false);
        }
        try {
            controlProveedor = new ControlProveedor();
            List<Proveedor> proveedores = controlProveedor.consultarProveedor();
            Integer idProveedor = Integer.parseInt(tablaProveedores.getValueAt(tablaProveedores.getSelectedRow(), 0).toString());

            for (Iterator iter = proveedores.iterator(); iter.hasNext();) {
                Proveedor pro = (Proveedor) iter.next();

                if (pro.getIdProveedor().equals(idProveedor)) {
                    if (!checkDireccion.isSelected()) {
                        direccionComp3.setText(pro.getDireccion());
                    }
                }
            }

        } catch (IOException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }
}//GEN-LAST:event_checkDireccionActionPerformed

    private void modificarProveedorActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_modificarProveedorActionPerformed
        try {
            controlProveedor = new ControlProveedor();
            List<Proveedor> proveedores = controlProveedor.consultarProveedor();
            Integer idProveedor = Integer.parseInt(tablaProveedores.getValueAt(tablaProveedores.getSelectedRow(), 0).toString());
            int row = tablaProveedores.getSelectedRow();

            for (Iterator iter = proveedores.iterator(); iter.hasNext();) {
                Proveedor pro = (Proveedor) iter.next();
                if (pro.getIdProveedor().equals(idProveedor)) {
                    if (checkNombre.isSelected()) {
                        pro.setNombre(nombre2.getText());
                    }
                    if (checkDireccion.isSelected()) {
                        pro.setDireccion(direccionComp3.getText());
                    }
                    if (checkTelefono.isSelected()) {
                        pro.setTelefono(nombre4.getText());
                    }
                    boolean result = controlProveedor.modificarProveedor(pro);
                    proveedores = controlProveedor.consultarProveedor();
                    if (result) {
                        this.cargarTablaProveedor(proveedores);
                        tablaProveedores.setRowSelectionInterval(row, row);
                        JOptionPane.showMessageDialog(aviso, "El proveedor ha sido modificado con Exito", "Nota", 1);
                    } else {
                        JOptionPane.showMessageDialog(aviso, "El proveedor no pudo ser modificado", "Warning", 1);
                    }
                }
            }

        } catch (IOException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }
}//GEN-LAST:event_modificarProveedorActionPerformed

    private void checkNombreActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_checkNombreActionPerformed

        if (checkNombre.isSelected()) {
            nombre2.setEnabled(true);
        } else {
            nombre2.setEnabled(false);
        }
        try {
            controlProveedor = new ControlProveedor();
            List<Proveedor> proveedores = controlProveedor.consultarProveedor();
            Integer idProveedor = Integer.parseInt(tablaProveedores.getValueAt(tablaProveedores.getSelectedRow(), 0).toString());
            for (Iterator iter = proveedores.iterator(); iter.hasNext();) {
                Proveedor pro = (Proveedor) iter.next();
                if (pro.getIdProveedor().equals(idProveedor)) {
                    if (!checkNombre.isSelected()) {
                        nombre2.setText(pro.getNombre());
                    }
                }
            }
        } catch (IOException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }
}//GEN-LAST:event_checkNombreActionPerformed

    private void nombre2ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_nombre2ActionPerformed
        // TODO add your handling code here:
}//GEN-LAST:event_nombre2ActionPerformed

    private void eliminarProveedorActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_eliminarProveedorActionPerformed
        int resultado = JOptionPane.showConfirmDialog(null, "Esta seguro que desea realizar esta operacion?", "ATENCION", JOptionPane.OK_CANCEL_OPTION);
        if (resultado == 0) {
            try {
                controlProveedor = new ControlProveedor();
                List<Proveedor> proveedores = controlProveedor.consultarProveedor();
                Integer idProveedor = Integer.parseInt(tablaProveedores.getValueAt(tablaProveedores.getSelectedRow(), 0).toString());
                for (int i = 0; i < proveedores.size(); i++) {
                    if (proveedores.get(i).getIdProveedor().equals(idProveedor)) {
                        boolean result = controlProveedor.eliminarProveedor(proveedores.get(i));
                        proveedores = controlProveedor.consultarProveedor();
                        if (result) {
                            this.cargarTablaProveedor(proveedores);
                            tablaProveedores.setRowSelectionInterval(0, 0);
                            JOptionPane.showMessageDialog(null, "El proveedor ha sido eliminado con Exito", "Resultado", JOptionPane.INFORMATION_MESSAGE);
                        } else {
                            JOptionPane.showMessageDialog(null, "Error: El ejecutivo no se pudo eliminar", "Resultado", JOptionPane.ERROR_MESSAGE);
                        }
                    }
                }
            } catch (IOException ex) {
                Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
            } catch (SQLException ex) {
                Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
            }
        }
}//GEN-LAST:event_eliminarProveedorActionPerformed

    private void telefonoActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_telefonoActionPerformed
        // TODO add your handling code here:
}//GEN-LAST:event_telefonoActionPerformed

    private void direccionActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_direccionActionPerformed
        // TODO add your handling code here:
}//GEN-LAST:event_direccionActionPerformed

    private void insertarProveedorActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_insertarProveedorActionPerformed
        try {
            controlProveedor = new ControlProveedor();
            if (nombre.getText().equals("")) {
                JOptionPane.showMessageDialog(aviso, "Debe llenar todos los campos ", "Warning", 1);
            } else {
                String Nombre = nombre.getText();
                String Direccion = direccion.getText();
                String Telefono = telefono.getText();
                double Porcentaje = 0.019;
                Proveedor proveedor = new Proveedor(Nombre, Direccion, Telefono, Porcentaje);
                boolean result = controlProveedor.agregarProveedor(proveedor);
                List<Proveedor> proveedores = controlProveedor.consultarProveedor();
                if (result) {
                    JOptionPane.showMessageDialog(aviso, "El proveedor ha sido agregado con Exito", "Nota", 1);
                    this.cargarTablaProveedor(proveedores);
                } else {
                    JOptionPane.showMessageDialog(aviso, "El proveedor no pudo ser agregado", "Nota", 1);
                }
            }
        } catch (IOException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }
}//GEN-LAST:event_insertarProveedorActionPerformed

    private void limpiarActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_limpiarActionPerformed
        nombre.setText("");
}//GEN-LAST:event_limpiarActionPerformed

    private void nombreActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_nombreActionPerformed

}//GEN-LAST:event_nombreActionPerformed

    private void mostrarProveedoresActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_mostrarProveedoresActionPerformed
        try {
            controlProveedor = new ControlProveedor();
            List<Proveedor> proveedores = controlProveedor.consultarProveedor();
            this.cargarTablaProveedor(proveedores);
        } catch (IOException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }
}//GEN-LAST:event_mostrarProveedoresActionPerformed

    private void tablaProveedoresMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_tablaProveedoresMouseClicked
        try {
            checkNombre.setEnabled(true);
            checkDireccion.setEnabled(true);
            checkTelefono.setEnabled(true);

            controlProveedor = new ControlProveedor();
            List<Proveedor> proveedores = controlProveedor.consultarProveedor();
            Integer idProveedor = Integer.parseInt(tablaProveedores.getValueAt(tablaProveedores.getSelectedRow(), 0).toString());

            for (int i = 0; i < proveedores.size(); i++) {
                if (proveedores.get(i).getIdProveedor().equals(idProveedor)) {
                    codigoProveedorEliminar.setText(proveedores.get(i).getIdProveedor().toString());
                    nombreProveedor.setText(proveedores.get(i).getNombre());
                    direccionProveedor.setText(proveedores.get(i).getDireccion());
                    telefonoProveedor.setText(proveedores.get(i).getTelefono());

                    codigoProveedorModificar.setText(proveedores.get(i).getIdProveedor().toString());
                    nombre2.setText(proveedores.get(i).getNombre());
                    direccionComp3.setText(proveedores.get(i).getDireccion());
                    nombre4.setText(proveedores.get(i).getTelefono());
                }
            }
        } catch (IOException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }
}//GEN-LAST:event_tablaProveedoresMouseClicked

    private void mostrarFacturasActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_mostrarFacturasActionPerformed
        this.cargarIdEventosSegundaCuota();
}//GEN-LAST:event_mostrarFacturasActionPerformed

    private void idEventosSegundaCuotaActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_idEventosSegundaCuotaActionPerformed
        try {
            controlEmpleado = new ControlEmpleado();
            controlEvento = new ControlEvento();
            List<Evento> eventos = controlEvento.consultarEventosSegundaCuota();

            this.asignarLabelEventosSegundaCuota(eventos);
            this.asignarLabelFechaCotizacion(eventos);
            this.cargarTablaFactura(eventos);
            this.cargarTablaEmpleadosContratados(eventos);
            this.calcularSubTotal();
            this.calcularIva();
            this.calcularDeposito();
            this.calcularTotal();
        } catch (IOException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }
}//GEN-LAST:event_idEventosSegundaCuotaActionPerformed

    private void cargarTablaEstadisticas(String numMes) {
        try {
            controlEvento = new ControlEvento();
            List<Evento> eventos = controlEvento.consultarEventosEstadistica();
            controlCotizacion = new ControlCotizacion();
            List<Cotizacion> cotizaciones = controlCotizacion.consultarCotizacionesFactura();
            controlRecibo = new ControlRecibo();
            List<Recibo> recibos = controlRecibo.consultarRecibo();
            controlOrdenCompra = new ControlOrdenCompra();
            List<OrdenCompra> ordenes = controlOrdenCompra.consultarOrdenCompraRecibo();
            controlUso = new ControlUso();
            List<Uso> usos = controlUso.consultarUsoEmpleado();

            controlEmpleado = new ControlEmpleado();
            List<Empleado> empleados = controlEmpleado.consultarEmpleadoEvento();

            long horasD = 0;
            double costoHora = 0.0;

            boolean flag = false;
            boolean flagcito = false;
            String mesFecha = "";
            DefaultTableModel dm = new DefaultTableModel();
            dm.addColumn("Código");
            dm.addColumn("Nombre del Evento");
            dm.addColumn("Monto Cotizado");
            dm.addColumn("Monto Subcontratado");
            dm.addColumn("Pago Personas Contratadas");
            Integer cantInsumos = 0;
            Vector insumos = new Vector();

            for (int i = 0; i < eventos.size(); i++) {
                String[] fecha = eventos.get(i).getFecha().toString().split("-");
                mesFecha = fecha[1];

                if (numMes.equals(mesFecha)) {
                    otrosGastos.setText("510.0");
                    flag = true;
                    for (int j = 0; j < cotizaciones.size(); j++) {
                        if (eventos.get(i).getIdEvento().equals(cotizaciones.get(j).getEventoIdEvento())) {
                            double montoRecibo = 0.0;
                            double acum = 0.0;
                            double nuevoMonto = 0.0;
                            for (int r = 0; r < recibos.size(); r++) {
                                if (eventos.get(i).getIdEvento().equals(recibos.get(r).getOrdenCompraCotizacionEventoIdEvento())) {
                                    montoRecibo = recibos.get(r).getMonto();
                                    acum = acum + montoRecibo;
                                    for (int k = 0; k < ordenes.size(); k++) {
                                        if (eventos.get(i).getIdEvento().equals(ordenes.get(k).getCotizacionEventoIdEvento())) {
                                            cantInsumos = ordenes.get(k).getCotizacionEventoIdEvento();
                                            cantInsumos = cantInsumos++;
                                        }
                                    }
                                    insumos.addElement(cantInsumos);
                                }
                            }
                            Vector pro = new Vector();
                            pro.addElement(eventos.get(i).getIdEvento());
                            pro.addElement(eventos.get(i).getDescripcion());
                            pro.addElement(cotizaciones.get(j).getMontoTotal());
                            nuevoMonto = this.redondear(acum, 2);
                            pro.addElement(nuevoMonto);

                            for (int u = 0; u < usos.size(); u++) {
                                if (eventos.get(i).getIdEvento().equals(usos.get(u).getEVENTO_idEVENTO())) {
                                    for (int k = 0; k < empleados.size(); k++) {
                                        if (usos.get(u).getEMPLEADO_cedula().equals(empleados.get(k).getCedula())) {
                                            flagcito = true;
                                            costoHora = costoHora + empleados.get(k).getCostoHoraContratado();
                                            Time horaI = Time.valueOf(eventos.get(i).getHoraInicio().toString());
                                            Time horaF = Time.valueOf(eventos.get(i).getHoraFin().toString());
                                            long diferencia = horaF.getTime() - horaI.getTime();
                                            horasD = diferencia / (1000 * 60 * 60);
                                        }
                                    }
                                }
                            }
                            if (flagcito) {
                                double monto = costoHora * horasD;
                                double montoContratado = this.redondear(monto, 2);
                                pro.addElement(montoContratado);
                            }
                            if (!flagcito) {
                                pro.addElement(0);
                            }
                            dm.addRow(pro);
                        }
                    }
                }
            }
            if (!flag) {
                JOptionPane.showMessageDialog(aviso, "No hubo eventos en este mes", "Warning", 1);
                gananciasPorMes.setForeground(Color.GRAY);
                perdidasPorMes.setForeground(Color.GRAY);
                gananciasPorMes.setText("0.0");
                perdidasPorMes.setText("0.0");
                montoCotizadoPorMes.setText("0.0");
                montoSubcontratadoPorMes.setText("0.0");
                gastoNomina.setText("0.0");
                otrosGastos.setText("0.0");
                cantidadEventosMes.setText("0");
                nombreClienteEstadistica.setText("Nombre Cliente");
                ciEstadistica.setText("--");
                horaInicioEstadistica.setText("00:00");
                horaFinEstadistica.setText("00:00");
                fechaEventoEstadistica.setText("----/--/--");
                telefonoEstadistica.setText("teléfono");
                ejecutivoEncargadoEstadistica.setText("Ejecutivo Encargado");
            }
            tablaEstadisticas.setModel(dm);
            cantidadEventosMes.setText(String.valueOf(tablaEstadisticas.getRowCount()));
            Integer cantEventos = tablaEstadisticas.getRowCount();

            double totalGastoNomina = this.redondear(2000.0 * cantEventos, 2);
            double acumGasto = 0.0;
//            gastoNomina.setText(String.valueOf(totalGastoNomina));

            for (int i = 0; i < tablaEstadisticas.getRowCount(); i++) {
                acumGasto = acumGasto + Double.valueOf(tablaEstadisticas.getValueAt(i, 4).toString());
                gastoNomina.setText(Double.toString(acumGasto+totalGastoNomina));
            }


            if (flag) {
                this.calcularMontoCotizadoPorMes();
                this.calcularMontoSubcontratadoPorMes();
                this.calcularTotalGananciasEstadisticas();
            }
        } catch (IOException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }
    }

    private void cargarTablaProveedor(List<Proveedor> proveedores) {

        DefaultTableModel dm = new DefaultTableModel();

        dm.addColumn("Código");
        dm.addColumn("Nombre");
        dm.addColumn("Dirección");
        dm.addColumn("Teléfono");

        for (int i = 0; i < proveedores.size(); i++) {
            Vector pro = new Vector();
            pro.addElement(proveedores.get(i).getIdProveedor());
            pro.addElement(proveedores.get(i).getNombre());
            pro.addElement(proveedores.get(i).getDireccion());
            pro.addElement(proveedores.get(i).getTelefono());

            dm.addRow(pro);
        }
        tablaProveedores.setModel(dm);
    }

    private void cargarTablaFactura(List<Evento> eventos) {
        DefaultTableModel dm = new DefaultTableModel();

        dm.addColumn("Cantidad");
        dm.addColumn("Concepto");
        dm.addColumn("Costo Unitario");
        dm.addColumn("Monto");
        try {
            controlCuota = new ControlCuota();
            List<Cuota> cuotas = controlCuota.consultarCuotaFactura();

            controlPago = new ControlPago();
            List<Pago> pagos = controlPago.consultarPagoFactura();

            controlCotizacion = new ControlCotizacion();
            List<Cotizacion> cotizaciones = controlCotizacion.consultarCotizacionesFactura();

            controlUso = new ControlUso();
            List<Uso> usos = controlUso.consultarUsoFactura();

            controlInsumo = new ControlInsumo();
            List<Insumo> insumos = controlInsumo.consultarInsumoFactura();

            controlInsumoInventario = new ControlInsumoInventario();
            List<InsumoInventario> insumoInventario = controlInsumoInventario.consultarInsumoInventarioFactura();

            if (idEventosSegundaCuota.getItemCount() != 0) {
                String idTmp[] = idEventosSegundaCuota.getSelectedItem().toString().split(", ");
                Integer id = Integer.parseInt(idTmp[0]);

                for (int i = 0; i < eventos.size(); i++) {
                    if (eventos.get(i).getIdEvento().equals(id)) {
                        for (int j = 0; j < cotizaciones.size(); j++) {
                            if (eventos.get(i).getIdEvento().equals(cotizaciones.get(j).getEventoIdEvento())) {
                                for (int u = 0; u < usos.size(); u++) {
                                    if (eventos.get(i).getIdEvento().equals(usos.get(u).getEVENTO_idEVENTO())) {
                                        for (int s = 0; s < insumos.size(); s++) {
                                            if (usos.get(u).getINSUMO_idINSUMO().equals(insumos.get(s).getIdINSUMO())) {
                                                for (int r = 0; r < insumoInventario.size(); r++) {
                                                    if (insumos.get(s).getIdINSUMO().equals(insumoInventario.get(r).getINSUMO_idINSUMO())) {
                                                        for (int p = 0; p < pagos.size(); p++) {
                                                            if (pagos.get(p).getCotizacionEventoIdEvento().equals(usos.get(u).getEVENTO_idEVENTO())) {
                                                                for (int a = 0; a < cuotas.size(); a++) {
                                                                    if (pagos.get(p).getIdPago().equals(cuotas.get(a).getPagoIdpago())) {
                                                                        if (cuotas.get(a).getCuota().equals("2")) {
                                                                            Vector even = new Vector();
                                                                            even.addElement(usos.get(u).getCantidad());
                                                                            even.addElement(insumos.get(s).getConcepto());
                                                                            even.addElement(insumoInventario.get(r).getCostoUnitario());
                                                                            even.addElement(usos.get(u).getCantidad() * insumoInventario.get(r).getCostoUnitario());

                                                                            dm.addRow(even);
                                                                        }
                                                                    }
                                                                }
                                                            }
                                                        }
                                                    }
                                                }
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
                tablaFactura.setModel(dm);
                tablaFactura.setEnabled(false);
            }
        } catch (IOException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }
    }

    private void cargarTablaEmpleadosContratados(List<Evento> eventos) {
        DefaultTableModel dm = new DefaultTableModel();

        dm.addColumn("Cedula");
        dm.addColumn("Nombre");
        dm.addColumn("Cargo");
        dm.addColumn("CostoHora");
        try {
            
            controlUso = new ControlUso();
            List<Uso> usos = controlUso.consultarUsoEmpleado();

            controlEmpleado = new ControlEmpleado();
            List<Empleado> empleados = controlEmpleado.consultarEmpleadoEvento();

            if (idEventosSegundaCuota.getItemCount() != 0) {
                String idTmp[] = idEventosSegundaCuota.getSelectedItem().toString().split(", ");
                Integer id = Integer.parseInt(idTmp[0]);

                for (int i = 0; i < eventos.size(); i++) {
                    if (eventos.get(i).getIdEvento().equals(id)) {
                        for (int j = 0; j < usos.size(); j++) {
                            if(id.equals(usos.get(j).getEVENTO_idEVENTO())){
                                for (int k = 0; k < empleados.size(); k++) {
                                    if(usos.get(j).getEMPLEADO_cedula().equals(empleados.get(k).getCedula())){
                                        Vector even = new Vector();

                                        even.addElement(usos.get(j).getEMPLEADO_cedula());
                                        even.addElement(empleados.get(k).getNombre()+"  "+empleados.get(k).getApellido());
                                        even.addElement(empleados.get(k).getCargoContratado());
                                        even.addElement(empleados.get(k).getCostoHoraContratado());

                                        dm.addRow(even);
                                    }
                                    
                                }
                            
                            
                            }
                            
                        }

                    }
                }
                tablaEmpleadosContratados.setModel(dm);
                tablaEmpleadosContratados.setEnabled(false);
            }
        } catch (IOException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }
    }

    private void cargarTablaFacturaCuadre(List<Evento> eventos) {

        DefaultTableModel dm = new DefaultTableModel();

        dm.addColumn("Cantidad");
        dm.addColumn("Concepto");
        dm.addColumn("Costo Unitario");
        dm.addColumn("Monto");
        try {
            controlCuota = new ControlCuota();
            List<Cuota> cuotas = controlCuota.consultarCuotaFactura();

            controlPago = new ControlPago();
            List<Pago> pagos = controlPago.consultarPagoFactura();

            controlCotizacion = new ControlCotizacion();
            List<Cotizacion> cotizaciones = controlCotizacion.consultarCotizacionesFactura();

            controlUso = new ControlUso();
            List<Uso> usos = controlUso.consultarUsoFactura();

            controlInsumo = new ControlInsumo();
            List<Insumo> insumos = controlInsumo.consultarInsumoFactura();

            controlInsumoInventario = new ControlInsumoInventario();
            List<InsumoInventario> insumoInventario = controlInsumoInventario.consultarInsumoInventarioFactura();

            if (idEventosCuadre.getItemCount() != 0) {
                String idTmp[] = idEventosCuadre.getSelectedItem().toString().split(", ");
                Integer id = Integer.parseInt(idTmp[0]);

                for (int i = 0; i < eventos.size(); i++) {
                    if (eventos.get(i).getIdEvento().equals(id)) {
                        for (int j = 0; j < cotizaciones.size(); j++) {
                            if (eventos.get(i).getIdEvento().equals(cotizaciones.get(j).getEventoIdEvento())) {
                                for (int u = 0; u < usos.size(); u++) {
                                    if (eventos.get(i).getIdEvento().equals(usos.get(u).getEVENTO_idEVENTO())) {
                                        for (int s = 0; s < insumos.size(); s++) {
                                            if (usos.get(u).getINSUMO_idINSUMO().equals(insumos.get(s).getIdINSUMO())) {
                                                for (int r = 0; r < insumoInventario.size(); r++) {
                                                    if (insumos.get(s).getIdINSUMO().equals(insumoInventario.get(r).getINSUMO_idINSUMO())) {
                                                        for (int p = 0; p < pagos.size(); p++) {
                                                            if (pagos.get(p).getCotizacionEventoIdEvento().equals(usos.get(u).getEVENTO_idEVENTO())) {
                                                                for (int a = 0; a < cuotas.size(); a++) {
                                                                    if (pagos.get(p).getIdPago().equals(cuotas.get(a).getPagoIdpago())) {
                                                                        if (cuotas.get(a).getCuota().equals("2")) {
                                                                            Vector even = new Vector();
                                                                            even.addElement(usos.get(u).getCantidad());
                                                                            even.addElement(insumos.get(s).getConcepto());
                                                                            even.addElement(insumoInventario.get(r).getCostoUnitario());
                                                                            even.addElement(usos.get(u).getCantidad() * insumoInventario.get(r).getCostoUnitario());
                                                                            dm.addRow(even);
                                                                        }
                                                                    }
                                                                }
                                                            }
                                                        }
                                                    }
                                                }
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
                tablaFacturaCuadre.setModel(dm);
                tablaFacturaCuadre.setEnabled(false);
                Integer filas = tablaFacturaCuadre.getRowCount();
                totalInsumoFacturado.setText(filas.toString());
            }
        } catch (IOException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }
    }

    private void calcularMontoTotalSubcontratadoCuadre() {
        Integer id = 0;
        try {
            controlEvento = new ControlEvento();
            List<Evento> eventos = controlEvento.consultarEventosRecibo();

            controlRecibo = new ControlRecibo();
            List<Recibo> recibos = controlRecibo.consultarReciboRecibo();

            controlOrdenCompra = new ControlOrdenCompra();
            List<OrdenCompra> ordenes = controlOrdenCompra.consultarOrdenCompraRecibo();

            controlInsumoInventario = new ControlInsumoInventario();
            List<InsumoInventario> insumoInventario = controlInsumoInventario.consultarInsumoInventarioRecibo();

            controlProveedor = new ControlProveedor();
            List<Proveedor> proveedores = controlProveedor.consultarProveedorRecibo();
            Vector even = new Vector();
            if (idEventosCuadre.getItemCount() != 0) {
                String idTmp[] = idEventosCuadre.getSelectedItem().toString().split(", ");
                id = Integer.parseInt(idTmp[0]);
                for (int i = 0; i < eventos.size(); i++) {
                    if (eventos.get(i).getIdEvento().equals(id)) {
                        for (int r = 0; r < recibos.size(); r++) {
                            if (eventos.get(i).getIdEvento().equals(recibos.get(r).getOrdenCompraCotizacionEventoIdEvento())) {
                                for (int o = 0; o < ordenes.size(); o++) {
                                    if (recibos.get(r).getOrdenCompraInsumoIdInsumo().equals(ordenes.get(o).getInsumoIdInsumo())) {
                                        for (int p = 0; p < proveedores.size(); p++) {
                                            if (proveedores.get(p).getIdProveedor().equals(ordenes.get(o).getProveedorIdProveedor())) {
                                                if (ordenes.get(o).getCotizacionIdCotizacion().equals(recibos.get(r).getOrdenCompraCotizacionEventoIdEvento())) {
                                                    for (int j = 0; j < insumoInventario.size(); j++) {
                                                        if (ordenes.get(o).getInsumoIdInsumo().equals(insumoInventario.get(j).getINSUMO_idINSUMO())) {
                                                            double costo = insumoInventario.get(j).getCostoUnitario();
                                                            double porcentaje = costo * 0.01;
                                                            double montoTot = costo - porcentaje;
                                                            double costoTotal = ordenes.get(o).getCantidad() * montoTot;
                                                            double montoFinal = this.redondear(costoTotal, 2);
                                                            even.addElement(montoFinal);
                                                        }
                                                    }
                                                }
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
            if (jcbProveedoresCuadre.getItemCount() != 0) {
                double acum = 0.0;
                for (int i = 0; i < even.size(); i++) {
                    totalInsumoSubcontratado.setText(String.valueOf(even.size()));
                    acum = acum + Double.valueOf(even.get(i).toString());
                    double monto = this.redondear(acum, 2);
                    montoTotalPerdido.setText(Double.toString(monto));
                }
            } else {
                totalInsumoSubcontratado.setText("0");
                montoTotalPerdido.setText("0.0");
            }
        } catch (IOException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }
    }

    private void calcularMontoTotalSubcontratado() {
        Integer id = 0;
        try {
            controlEvento = new ControlEvento();
            List<Evento> eventos = controlEvento.consultarEventosRecibo();

            controlRecibo = new ControlRecibo();
            List<Recibo> recibos = controlRecibo.consultarReciboRecibo();

            controlOrdenCompra = new ControlOrdenCompra();
            List<OrdenCompra> ordenes = controlOrdenCompra.consultarOrdenCompraRecibo();

            controlInsumoInventario = new ControlInsumoInventario();
            List<InsumoInventario> insumoInventario = controlInsumoInventario.consultarInsumoInventarioRecibo();

            controlProveedor = new ControlProveedor();
            List<Proveedor> proveedores = controlProveedor.consultarProveedorRecibo();
            Vector even = new Vector();
            if (jcbInsumosSubcontratados.getItemCount() != 0) {
                String idTmp[] = jcbInsumosSubcontratados.getSelectedItem().toString().split(", ");
                id = Integer.parseInt(idTmp[0]);
                for (int i = 0; i < eventos.size(); i++) {
                    if (eventos.get(i).getIdEvento().equals(id)) {
                        for (int r = 0; r < recibos.size(); r++) {
                            if (eventos.get(i).getIdEvento().equals(recibos.get(r).getOrdenCompraCotizacionEventoIdEvento())) {
                                for (int o = 0; o < ordenes.size(); o++) {
                                    if (recibos.get(r).getOrdenCompraInsumoIdInsumo().equals(ordenes.get(o).getInsumoIdInsumo())) {
                                        for (int p = 0; p < proveedores.size(); p++) {
                                            if (proveedores.get(p).getIdProveedor().equals(ordenes.get(o).getProveedorIdProveedor())) {
                                                if (ordenes.get(o).getCotizacionIdCotizacion().equals(recibos.get(r).getOrdenCompraCotizacionEventoIdEvento())) {
                                                    for (int j = 0; j < insumoInventario.size(); j++) {
                                                        if (ordenes.get(o).getInsumoIdInsumo().equals(insumoInventario.get(j).getINSUMO_idINSUMO())) {
                                                            double costo = insumoInventario.get(j).getCostoUnitario();
                                                            double porcentaje = costo * 0.01;
                                                            double montoTot = costo - porcentaje;
                                                            double costoTotal = ordenes.get(o).getCantidad() * montoTot;
                                                            double montoFinal = this.redondear(costoTotal, 2);
                                                            even.addElement(montoFinal);
                                                        }
                                                    }
                                                }
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
            double acum = 0.0;
            for (int i = 0; i < even.size(); i++) {
                labelTotalInsumos.setText(String.valueOf(even.size()));
                acum = acum + Double.valueOf(even.get(i).toString());
                double monto = this.redondear(acum, 2);
                totalSubcontratadoRecibo.setText(Double.toString(monto));
            }
        } catch (IOException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }
    }

    private void calcularMontoTotalRecibo() {
        double acum = 0.0;
        for (int i = 0; i < tablaInsumosSubcontratados.getRowCount(); i++) {
            acum = acum + Double.valueOf(tablaInsumosSubcontratados.getValueAt(i, 4).toString());
            double monto = this.redondear(acum, 2);
            totalPagoPorProveedorRecibo.setText(Double.toString(monto));
        }
    }

    private void calcularMontoTotalCuadre() {
        double acum = 0.0;
        for (int i = 0; i < tablaInsumosSubcontratadosCuadre.getRowCount(); i++) {
            acum = acum + Double.valueOf(tablaInsumosSubcontratadosCuadre.getValueAt(i, 4).toString());
            double monto = this.redondear(acum, 2);
            totalPagoPorProveedorCuadre.setText(Double.toString(monto));
        }
    }

    private void calcularSubTotal() {
        double acum = 0.0;
        for (int i = 0; i < tablaFactura.getRowCount(); i++) {
            acum = acum + Double.valueOf(tablaFactura.getValueAt(i, 3).toString());
            subtotal1.setText(Double.toString(acum));
        }
    }

    private void calcularIva() {
        double monto = Double.valueOf(subtotal1.getText());
        double ivaValor = monto * 0.09;
        double resultado = this.redondear(ivaValor, 2);
        iva1.setText(Double.toString(resultado));
    }

    private void calcularDeposito() {
        double monto = Double.valueOf(subtotal1.getText());
        double depValor = monto * 0.05;
        double resultado = this.redondear(depValor, 2);
        deposito1.setText(Double.toString(resultado));
    }

    private void calcularTotal() {
        double Subtotal = Double.valueOf(subtotal1.getText().toString());
        double Iva = Double.valueOf(iva1.getText().toString());
        double Deposito = Double.valueOf(deposito1.getText().toString());
        double resultado = this.redondear(Subtotal + Iva + Deposito, 2);
        pagoTotalLabel.setText(Double.toString(resultado));
    }

    private void calcularSubTotalCuadre() {
        double acum = 0.0;
        for (int i = 0; i < tablaFacturaCuadre.getRowCount(); i++) {
            acum = acum + Double.valueOf(tablaFacturaCuadre.getValueAt(i, 3).toString());
            subtotalCuadre.setText(Double.toString(acum));
        }
    }

    private void calcularIvaCuadre() {
        double monto = Double.valueOf(subtotalCuadre.getText());
        double ivaValor = monto * 0.09;
        double resultado = this.redondear(ivaValor, 2);
        ivaCuadre.setText(Double.toString(resultado));
    }

    private void calcularDepositoCuadre() {
        double monto = Double.valueOf(subtotalCuadre.getText());
        double depValor = monto * 0.05;
        double resultado = this.redondear(depValor, 2);
        depositoCuadre.setText(Double.toString(resultado));
    }

    private void calcularTotalCuadre() {
        double Subtotal = Double.valueOf(subtotalCuadre.getText().toString());
        double Iva = Double.valueOf(ivaCuadre.getText().toString());
        double Deposito = Double.valueOf(depositoCuadre.getText().toString());
        double resultado = this.redondear(Subtotal + Iva + Deposito, 2);
        pagoTotalLabelCuadre.setText(Double.toString(resultado));
    }

    private void calcularTotalGanancias() {
        double montoFacturado = Double.valueOf(pagoTotalLabelCuadre.getText().toString());
        double montoSubcontratado = Double.valueOf(montoTotalPerdido.getText().toString());
        double montoPersonasContratadas = Double.valueOf(gastoContratados.getText().toString());
        double gastos = montoSubcontratado + montoPersonasContratadas;

        if (montoFacturado > gastos) {
            labelGanadoPerdido.setText("ganado");
            montoTotalGanado.setForeground(Color.GREEN.darker());
            double resultado = this.redondear(montoFacturado - gastos, 2);
            montoTotalGanado.setText(Double.toString(resultado));

        } else {
            if (montoFacturado < gastos) {
                labelGanadoPerdido.setText("perdido");
                montoTotalGanado.setForeground(Color.red.darker());
                double resultado = this.redondear(montoFacturado - gastos, 2);
                montoTotalGanado.setText(Double.toString(resultado));
            }
        }

    }

    private void cantidadInsumosDelProveedor() {
        Integer acum = 0;
        for (int i = 0; i < tablaInsumosSubcontratados.getRowCount(); i++) {
            acum = acum + Integer.parseInt(tablaInsumosSubcontratados.getValueAt(i, 1).toString());
            cantidadInsumosProveedor.setText(acum.toString());
        }
    }

    private void calcularMontoCotizadoPorMes() {
        double acum = 0.0;
        for (int i = 0; i < tablaEstadisticas.getRowCount(); i++) {
            acum = acum + Double.valueOf(tablaEstadisticas.getValueAt(i, 2).toString());
            montoCotizadoPorMes.setText(Double.toString(acum));
        }
    }

    private void calcularMontoSubcontratadoPorMes() {
        double acum = 0.0;
        for (int i = 0; i < tablaEstadisticas.getRowCount(); i++) {
            acum = acum + Double.valueOf(tablaEstadisticas.getValueAt(i, 3).toString());
            montoSubcontratadoPorMes.setText(Double.toString(acum));
        }
    }

    private void calcularTotalGananciasEstadisticas() {
        double montoFacturado = Double.valueOf(montoCotizadoPorMes.getText().toString());
        double montoSubcontratado = Double.valueOf(montoSubcontratadoPorMes.getText().toString());
        double montoNomina = Double.parseDouble(gastoNomina.getText().toString());
        double montoOtrosGastos = Double.parseDouble(otrosGastos.getText().toString());
        double gastos = montoSubcontratado + montoNomina + montoOtrosGastos;
        if (montoFacturado > gastos) {
            gananciasPorMes.setForeground(Color.GREEN.darker());
            double resultado = this.redondear(montoFacturado - gastos, 2);
            gananciasPorMes.setText(Double.toString(resultado));

        } else {
            if (montoFacturado < gastos) {
                perdidasPorMes.setForeground(Color.red.darker());
                double resultado = this.redondear(montoFacturado - gastos, 2);
                perdidasPorMes.setText(Double.toString(resultado));
            }
        }
    }

    private double redondear(double numero, int decimales) {
        return Math.round(numero * Math.pow(10, decimales)) / Math.pow(10, decimales);
    }

    private void validarCampos() {
        CampoNumerico cn = new CampoNumerico();
        cn.validarCampo(numeroCheque1);
        cn.validarCampo(telefono);
        cn.validarCampo(numeroTarjeta1);
        cn.validarCampo(codigoSeguridad1);
    }

    private void cargarTablaProveedores(List<Proveedor> proveedores) {

        DefaultTableModel dm = new DefaultTableModel();

        dm.addColumn("Código");
        dm.addColumn("Nombre");
        dm.addColumn("Telefono");

        if (jcbEventosInsumosASubcontratar.getItemCount() == 0) {
            jcbEventosInsumosASubcontratar.setVisible(true);
        } else {
            for (int i = 0; i < proveedores.size(); i++) {
                Vector pro = new Vector();
                pro.addElement(proveedores.get(i).getIdProveedor());
                pro.addElement(proveedores.get(i).getNombre());
                pro.addElement(proveedores.get(i).getTelefono());

                dm.addRow(pro);
            }
            tablaProveedor.setModel(dm);
        }

    }

    private void cargarTablaInsumosASubcontratar(List<Evento> eventos) {
        Integer id = 0;
        DefaultTableModel dm = new DefaultTableModel();

        dm.addColumn("Código");
        dm.addColumn("Concepto");
        dm.addColumn("Cantidad");
        dm.addColumn("Costo Unitario");
        try {
            controlUso = new ControlUso();
            List<Uso> usos = controlUso.consultarUsoInsumoASubcontratar();

            controlOrdenCompra = new ControlOrdenCompra();
            List<OrdenCompra> ordenes = controlOrdenCompra.consultarOrdenCompra();

            controlInsumoInventario = new ControlInsumoInventario();
            List<InsumoInventario> insumoInventario = controlInsumoInventario.consultarInsumoInventarioASubcontratar();

            controlInsumo = new ControlInsumo();
            List<Insumo> insumos = controlInsumo.consultarInsumosASubcontratar();

            Vector cantInsumoUso = new Vector();
            Vector cantInsumosOrden = new Vector();

            if (jcbEventosInsumosASubcontratar.getItemCount() != 0) {
                String idTmp[] = jcbEventosInsumosASubcontratar.getSelectedItem().toString().split(", ");
                id = Integer.parseInt(idTmp[0]);
                for (int i = 0; i < eventos.size(); i++) { // eventos con los insumos a subcontratar
                    if (eventos.get(i).getIdEvento().equals(id)) {
                        for (int z = 0; z < usos.size(); z++) {
                            if (id.equals(usos.get(z).getEVENTO_idEVENTO())) {
                                cantInsumoUso.addElement(usos.get(z).getINSUMO_idINSUMO());
                            }
                        }
                        boolean flag = false;
                        for (int o = 0; o < ordenes.size(); o++) {
                            if (id.equals(ordenes.get(o).getCotizacionEventoIdEvento())) {
                                cantInsumosOrden.addElement(ordenes.get(o).getInsumoIdInsumo());
                                flag = true;
                            }
                        }
                        Integer insumoTabla = 0;

                        if (flag == true) {
                            if (cantInsumosOrden.size() < cantInsumoUso.size()) {
                                for (int c = 0; c < cantInsumoUso.size(); c++) {
                                    for (int o = 0; o < cantInsumosOrden.size(); o++) {
                                        if (!cantInsumoUso.get(c).equals(cantInsumosOrden.get(o))) {
                                            insumoTabla = Integer.parseInt(cantInsumoUso.get(c).toString());

                                            for (int u = 0; u < insumos.size(); u++) {
                                                if (insumoTabla.equals(insumos.get(u).getIdINSUMO())) {
                                                    Vector even = new Vector();
                                                    even.addElement(insumoTabla);
                                                    even.addElement(insumos.get(u).getConcepto());


                                                    for (int r = 0; r < insumoInventario.size(); r++) {
                                                        if (insumoTabla.equals(insumoInventario.get(r).getINSUMO_idINSUMO())) {
                                                            Integer cantInsumoInventario = insumoInventario.get(r).getCantidad();
                                                            for (int z = 0; z < usos.size(); z++) {
                                                                if (usos.get(z).getINSUMO_idINSUMO().equals(insumoTabla)) {
                                                                    if (usos.get(z).getCantidad() > cantInsumoInventario) {
                                                                        Integer cant = usos.get(z).getCantidad() - cantInsumoInventario;
                                                                        even.addElement(cant);
                                                                        even.addElement(0);
                                                                    }
                                                                }
                                                            }
                                                        }
                                                    }



                                                    dm.addRow(even);
                                                }
                                            }
                                        }
                                    }
                                }
                            }
                        } else {
                            if (flag == false) {
                                for (int s = 0; s < usos.size(); s++) {
                                    if (id.equals(usos.get(s).getEVENTO_idEVENTO())) {
                                        insumoTabla = usos.get(s).getINSUMO_idINSUMO();
                                        for (int u = 0; u < insumos.size(); u++) {
                                            if (insumoTabla.equals(insumos.get(u).getIdINSUMO())) {
                                                Vector even = new Vector();
                                                even.addElement(insumos.get(u).getIdINSUMO());
                                                even.addElement(insumos.get(u).getConcepto());

                                                for (int r = 0; r < insumoInventario.size(); r++) {
                                                    if (insumoTabla.equals(insumoInventario.get(r).getINSUMO_idINSUMO())) {
                                                        Integer cantInsumoInventario = insumoInventario.get(r).getCantidad();
                                                        if (usos.get(s).getCantidad() > cantInsumoInventario) {
                                                            Integer cant = usos.get(s).getCantidad() - cantInsumoInventario;
                                                            even.addElement(cant);
                                                            even.addElement(0);
                                                        }
                                                    }
                                                }
                                                dm.addRow(even);
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
                tablaInsumosASubcontratar.setModel(dm);
            } else {
                if (jcbEventosInsumosASubcontratar.getItemCount() == 0) {
                    Vector vacio = new Vector();
                    vacio.addElement("0");
                    vacio.addElement("--");
                    vacio.addElement("0");
                    vacio.addElement("0");
                    dm.addRow(vacio);
                    tablaInsumosASubcontratar.setModel(dm);
                }
            }
        } catch (IOException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }

    }

    private void cargarTablaInsumosSubcontratados(List<Proveedor> proveedores) {
        Integer idProveedor = 0;
        Integer idEvento = 0;
        DefaultTableModel dm = new DefaultTableModel();

        dm.addColumn("Fecha");
        dm.addColumn("Cantidad");
        dm.addColumn("Concepto");
        dm.addColumn("Costo Unitario");
        dm.addColumn("Monto");

        try {
            controlRecibo = new ControlRecibo();
            List<Recibo> recibos = controlRecibo.consultarReciboRecibo();

            controlOrdenCompra = new ControlOrdenCompra();
            List<OrdenCompra> ordenes = controlOrdenCompra.consultarOrdenCompraRecibo();

            controlInsumoInventario = new ControlInsumoInventario();
            List<InsumoInventario> insumoInventario = controlInsumoInventario.consultarInsumoInventarioRecibo();

            controlInsumo = new ControlInsumo();
            List<Insumo> insumos = controlInsumo.consultarInsumoRecibo();

            if (jcbInsumosSubcontratados.getItemCount() != 0) {
                String idTmp[] = jcbInsumosSubcontratados.getSelectedItem().toString().split(", ");
                idEvento = Integer.parseInt(idTmp[0]);
            }

            if (jcbProveedoresRecibo.getItemCount() != 0) {
                String idTmp[] = jcbProveedoresRecibo.getSelectedItem().toString().split(", ");
                idProveedor = Integer.parseInt(idTmp[0]);

                for (int p = 0; p < proveedores.size(); p++) {
                    if (proveedores.get(p).getIdProveedor().equals(idProveedor)) {
                        for (int o = 0; o < ordenes.size(); o++) {
                            if (proveedores.get(p).getIdProveedor().equals(ordenes.get(o).getProveedorIdProveedor())) {
                                if (idEvento.equals(ordenes.get(o).getCotizacionEventoIdEvento())) {
                                    for (int r = 0; r < recibos.size(); r++) {
                                        if (ordenes.get(o).getCotizacionEventoIdEvento().equals(recibos.get(r).getOrdenCompraCotizacionEventoIdEvento())) {
                                            if (recibos.get(r).getOrdenCompraInsumoIdInsumo().equals(ordenes.get(o).getInsumoIdInsumo())) {
                                                for (int i = 0; i < insumos.size(); i++) {
                                                    if (ordenes.get(o).getInsumoIdInsumo().equals(insumos.get(i).getIdINSUMO())) {
                                                        for (int j = 0; j < insumoInventario.size(); j++) {
                                                            if (insumos.get(i).getIdINSUMO().equals(insumoInventario.get(j).getINSUMO_idINSUMO())) {
                                                                Vector even = new Vector();
                                                                even.addElement(recibos.get(r).getFecha().toString());
                                                                even.addElement(ordenes.get(o).getCantidad());
                                                                even.addElement(recibos.get(r).getConcepto());
                                                                double costo = insumoInventario.get(j).getCostoUnitario();
                                                                double porcentaje = costo * 0.01;
                                                                double montoTot = costo - porcentaje;
                                                                double costoTotal = ordenes.get(o).getCantidad() * montoTot;
                                                                double montoFinal = this.redondear(costoTotal, 2);
                                                                even.addElement(costo - porcentaje);
                                                                even.addElement(montoFinal);
                                                                dm.addRow(even);
                                                            }
                                                        }
                                                    }
                                                }
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
                tablaInsumosSubcontratados.setModel(dm);
                tablaInsumosSubcontratados.setEnabled(false);
                this.cantidadInsumosDelProveedor();
            }
        } catch (IOException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }
    }

    private void cargarTablaInsumosSubcontratadosCuadre(List<Proveedor> proveedores) {
        Integer idProveedor = 0;
        Integer idEvento = 0;
        DefaultTableModel dm = new DefaultTableModel();

        dm.addColumn("Fecha");
        dm.addColumn("Cantidad");
        dm.addColumn("Concepto");
        dm.addColumn("Costo Unitario");
        dm.addColumn("Monto");

        try {
            controlRecibo = new ControlRecibo();
            List<Recibo> recibos = controlRecibo.consultarReciboRecibo();

            controlOrdenCompra = new ControlOrdenCompra();
            List<OrdenCompra> ordenes = controlOrdenCompra.consultarOrdenCompraRecibo();

            controlInsumoInventario = new ControlInsumoInventario();
            List<InsumoInventario> insumoInventario = controlInsumoInventario.consultarInsumoInventarioRecibo();

            controlInsumo = new ControlInsumo();
            List<Insumo> insumos = controlInsumo.consultarInsumoRecibo();

            if (idEventosCuadre.getItemCount() != 0) {
                String idTmp[] = idEventosCuadre.getSelectedItem().toString().split(", ");
                idEvento = Integer.parseInt(idTmp[0]);
            }

            if (jcbProveedoresCuadre.getItemCount() != 0) {
                String idTmp[] = jcbProveedoresCuadre.getSelectedItem().toString().split(", ");
                idProveedor = Integer.parseInt(idTmp[0]);

                for (int p = 0; p < proveedores.size(); p++) {
                    if (proveedores.get(p).getIdProveedor().equals(idProveedor)) {
                        for (int o = 0; o < ordenes.size(); o++) {
                            if (proveedores.get(p).getIdProveedor().equals(ordenes.get(o).getProveedorIdProveedor())) {
                                if (idEvento.equals(ordenes.get(o).getCotizacionEventoIdEvento())) {
                                    for (int r = 0; r < recibos.size(); r++) {
                                        if (ordenes.get(o).getCotizacionEventoIdEvento().equals(recibos.get(r).getOrdenCompraCotizacionEventoIdEvento())) {
                                            if (recibos.get(r).getOrdenCompraInsumoIdInsumo().equals(ordenes.get(o).getInsumoIdInsumo())) {
                                                for (int i = 0; i < insumos.size(); i++) {
                                                    if (ordenes.get(o).getInsumoIdInsumo().equals(insumos.get(i).getIdINSUMO())) {
                                                        for (int j = 0; j < insumoInventario.size(); j++) {
                                                            if (insumos.get(i).getIdINSUMO().equals(insumoInventario.get(j).getINSUMO_idINSUMO())) {
                                                                Vector even = new Vector();

                                                                even.addElement(recibos.get(r).getFecha().toString());
                                                                even.addElement(ordenes.get(o).getCantidad());
                                                                even.addElement(recibos.get(r).getConcepto());
                                                                double costo = insumoInventario.get(j).getCostoUnitario();
                                                                double porcentaje = costo * 0.01;
                                                                double montoTot = costo - porcentaje;
                                                                double costoTotal = ordenes.get(o).getCantidad() * montoTot;
                                                                double montoFinal = this.redondear(costoTotal, 2);
                                                                even.addElement(costo - porcentaje);

                                                                even.addElement(montoFinal);
                                                                dm.addRow(even);
                                                            }
                                                        }
                                                    }
                                                }
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
                tablaInsumosSubcontratadosCuadre.setModel(dm);
                tablaInsumosSubcontratadosCuadre.setEnabled(false);
            } else {
                if (jcbProveedoresCuadre.getItemCount() == 0) {
                    Vector vacio = new Vector();
                    vacio.addElement("0");
                    vacio.addElement("--");
                    vacio.addElement("0");
                    vacio.addElement("0");
                    vacio.addElement("0.0");
                    dm.addRow(vacio);
                    tablaInsumosSubcontratadosCuadre.setModel(dm);
                }

            }

        } catch (IOException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }
    }


    private void cargarIdEventosSegundaCuota() {

        idEventosSegundaCuota.setVisible(false);
        if (idEventosSegundaCuota.isPopupVisible() != true) {
            idEventosSegundaCuota.removeAllItems();
        }
        try {
            controlEvento = new ControlEvento();
            List<Evento> eventos = controlEvento.consultarEventosSegundaCuota();
            for (int i = 0; i < eventos.size(); i++) {
                Integer id = eventos.get(i).getIdEvento();
                String descripcion = eventos.get(i).getDescripcion();
                idEventosSegundaCuota.addItem(id + ", " + descripcion);
            }
        } catch (IOException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }
        idEventosSegundaCuota.setVisible(true);
    }

    private void cargarIdEventosCuadre() {

        idEventosCuadre.setVisible(false);
        if (idEventosCuadre.isPopupVisible() != true) {
            idEventosCuadre.removeAllItems();
        }
        try {
            controlEvento = new ControlEvento();
            List<Evento> eventos = controlEvento.consultarEventosSegundaCuota();
            for (int i = 0; i < eventos.size(); i++) {
                Integer id = eventos.get(i).getIdEvento();
                String descripcion = eventos.get(i).getDescripcion();
                idEventosCuadre.addItem(id + ", " + descripcion);
            }
        } catch (IOException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }
        idEventosCuadre.setVisible(true);
    }

   
    private void cargarJcbProveedoresCuadre() {
        try {
            Integer idEvento = 0;
            Integer id = 0;
            String concepto = null;
            String id2 = null;
            String concepto2 = null;
            String comparacion = null;
            String comparacionNueva = null;
            jcbProveedoresCuadre.setVisible(false);
            if (jcbProveedoresCuadre.isPopupVisible() != true) {
                jcbProveedoresCuadre.removeAllItems();
            }
            controlOrdenCompra = new ControlOrdenCompra();
            List<OrdenCompra> ordenes = controlOrdenCompra.consultarOrdenCompraProveedor();

            controlProveedor = new ControlProveedor();
            List<Proveedor> proveedores = controlProveedor.consultarProveedorProveedor();

            if (idEventosCuadre.getItemCount() != 0) {
                String[] idTmp = idEventosCuadre.getSelectedItem().toString().split(", ");
                idEvento = Integer.parseInt(idTmp[0]);

                for (OrdenCompra o : ordenes) {
                    boolean flag = true;
                    for (Proveedor p : proveedores) {
                        if ((p.getIdProveedor().equals(o.getProveedorIdProveedor())) && flag && (o.getCotizacionEventoIdEvento().equals(idEvento))) {
                            id = p.getIdProveedor();
                            concepto = p.getNombre();
                            comparacionNueva = id + ", " + concepto;
                            if (jcbProveedoresCuadre.getItemCount() == 0) {
                                jcbProveedoresCuadre.addItem(id + ", " + concepto);
                                id2 = id.toString();
                                concepto2 = concepto;
                                comparacion = id2 + ", " + concepto2;
                            }
                            if (jcbProveedoresCuadre.getItemCount() != 0) {
                                if (!comparacion.equals(comparacionNueva)) {
                                    jcbProveedoresCuadre.addItem(id + ", " + concepto);
                                    id2 = id.toString();
                                    concepto2 = concepto;
                                    comparacion = id2 + ", " + concepto2;
                                }
                            }
                            flag = false;
                        }
                    }
                }
            }
            jcbProveedoresCuadre.setVisible(true);
        } catch (IOException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }
    }

    private void cargarJcbEventosInsumosASubcontratar(List<Evento> eventos) {
        try {
            controlUso = new ControlUso();
            List<Uso> usos = controlUso.consultarUsoInsumoASubcontratar();
            controlOrdenCompra = new ControlOrdenCompra();
            List<OrdenCompra> ordenes = controlOrdenCompra.consultarOrdenCompra();
            Vector cantInsumoUso = new Vector();
            Vector cantInsumosOrden = new Vector();

            jcbEventosInsumosASubcontratar.setVisible(false);
            if (jcbEventosInsumosASubcontratar.isPopupVisible() != true) {
                jcbEventosInsumosASubcontratar.removeAllItems();
            }
            for (int i = 0; i < eventos.size(); i++) {
                cantInsumoUso.removeAllElements();
                cantInsumosOrden.removeAllElements();
                Integer id = eventos.get(i).getIdEvento();
                String descripcion = eventos.get(i).getDescripcion();
                for (int j = 0; j < usos.size(); j++) {
                    if (id.equals(usos.get(j).getEVENTO_idEVENTO())) {
                        cantInsumoUso.addElement(usos.get(j).getINSUMO_idINSUMO());
                    }
                }
                boolean flag = false;
                for (int o = 0; o < ordenes.size(); o++) {
                    if (id.equals(ordenes.get(o).getCotizacionEventoIdEvento())) {
                        cantInsumosOrden.addElement(ordenes.get(o).getInsumoIdInsumo());
                        flag = true;
                    }
                }
                if (flag = true) {
                    Integer cantidades = cantInsumosOrden.size() - cantInsumoUso.size();
                    if (cantidades < 0 && cantidades != 0) {
                        jcbEventosInsumosASubcontratar.addItem(id + ", " + descripcion);
                    }
                }
                if (flag == false) {
                    jcbEventosInsumosASubcontratar.addItem(id + ", " + descripcion);
                }
            }
            jcbEventosInsumosASubcontratar.setVisible(true);
            if (jcbEventosInsumosASubcontratar.getItemCount() == 0) {
                jcbEventosInsumosASubcontratar.setVisible(true);
                JOptionPane.showMessageDialog(aviso, "No existen insumos para subcontratar", "Warning", 1);
            }
        } catch (IOException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }
    }

    private void cargarjcbInsumosSubcontratados(List<Evento> eventos) {

        jcbInsumosSubcontratados.setVisible(false);
        if (jcbInsumosSubcontratados.isPopupVisible() != true) {
            jcbInsumosSubcontratados.removeAllItems();
        }
        for (int i = 0; i < eventos.size(); i++) {
            Integer id = eventos.get(i).getIdEvento();
            String descripcion = eventos.get(i).getDescripcion();
            jcbInsumosSubcontratados.addItem(id + ", " + descripcion);
        }
        jcbInsumosSubcontratados.setVisible(true);

    }

    private void asignarLabelEventosSegundaCuota(List<Evento> eventos) {
        try {
            controlEmpleado = new ControlEmpleado();
            List<Empleado> ejecutivos = controlEmpleado.consultarEjecutivosEncargado();
            controlEvento = new ControlEvento();
            List<Evento> eventoEjecutivo = controlEvento.consultarEventosEjecutivo();
            if (idEventosSegundaCuota.getItemCount() != 0) {
                String[] idTmp = idEventosSegundaCuota.getSelectedItem().toString().split(", ");
                Integer id = Integer.parseInt(idTmp[0]);
                for (int i = 0; i < eventos.size(); i++) {
                    if (eventos.get(i).getIdEvento().equals(id)) {

                        nroFacturaLabel.setText("00103" + eventos.get(i).getIdEvento().toString());
                        fechaLabel.setText(eventos.get(i).getFecha().toString());
                        horaInicio.setText(eventos.get(i).getHoraInicio().toString());
                        horaFin.setText(eventos.get(i).getHoraFin().toString());
                        lugarEvento.setText(eventos.get(i).getLugar());
                        System.out.println("lugar: "+eventos.get(i).getLugar());
                    }
                }
                for (int z = 0; z < eventoEjecutivo.size(); z++) {
                    if (eventoEjecutivo.get(z).getIdEvento().equals(id)) {
                        for (int j = 0; j < ejecutivos.size(); j++) {
                            if (eventoEjecutivo.get(z).getEjecutivoCedula().equals(ejecutivos.get(j).getCedula())) {
                                ejecutivoEncargadoLabel.setText(ejecutivos.get(j).getNombre() + " " + ejecutivos.get(j).getApellido());
                            }
                        }

                    }
                }
            }
        } catch (IOException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }
    }

    private void asignarLabelEventosCuadre(List<Evento> eventos) {
        try {
            controlEmpleado = new ControlEmpleado();
            List<Empleado> ejecutivos = controlEmpleado.consultarEjecutivosEncargado();
            controlEvento = new ControlEvento();
            List<Evento> eventoEjecutivo = controlEvento.consultarEventosEjecutivo();

            if (idEventosCuadre.getItemCount() != 0) {
                String[] idTmp = idEventosCuadre.getSelectedItem().toString().split(", ");
                Integer id = Integer.parseInt(idTmp[0]);
                for (int i = 0; i < eventos.size(); i++) {
                    if (eventos.get(i).getIdEvento().equals(id)) {

                        fechaEventoCuadre.setText(eventos.get(i).getFecha().toString());
                        horaInicioCuadre.setText(eventos.get(i).getHoraInicio().toString());
                        horaFinCuadre.setText(eventos.get(i).getHoraFin().toString());
                    }
                }
                for (int z = 0; z < eventoEjecutivo.size(); z++) {
                    if (eventoEjecutivo.get(z).getIdEvento().equals(id)) {
                        for (int j = 0; j < ejecutivos.size(); j++) {
                            if (eventoEjecutivo.get(z).getEjecutivoCedula().equals(ejecutivos.get(j).getCedula())) {
                                ejecutivoEncargadoCuadre.setText(ejecutivos.get(j).getNombre() + " " + ejecutivos.get(j).getApellido());
                            }
                        }

                    }
                }
            }
        } catch (IOException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }
    }

    private void asignarLabelFechaCotizacion(List<Evento> eventos) {

        try {
            controlCotizacion = new ControlCotizacion();
            List<Cotizacion> cotizaciones = controlCotizacion.consultarFechaCotizaciones();

            controlClienteCompania = new ControlClienteCompania();
            List<ClienteCompania> companias = controlClienteCompania.consultarClienteCompaniaSegundaCuota();

            controlClienteParticular = new ControlClienteParticular();
            List<ClienteParticular> particular = controlClienteParticular.consultarClienteParticularSegundaCuota();

            if (idEventosSegundaCuota.getItemCount() != 0) {
                String idTmp[] = idEventosSegundaCuota.getSelectedItem().toString().split(", ");
                Integer id = Integer.parseInt(idTmp[0]);

                for (int i = 0; i < eventos.size(); i++) {
                    if (eventos.get(i).getIdEvento().equals(id)) {
                        for (int j = 0; j < cotizaciones.size(); j++) {
                            if (eventos.get(i).getIdEvento().equals(cotizaciones.get(j).getEventoIdEvento())) {
                                fechaCotizacionLabel.setText(eventos.get(i).getFecha().toString());

                                Time horaI = Time.valueOf(eventos.get(i).getHoraInicio().toString());
                                Time horaF = Time.valueOf(eventos.get(i).getHoraFin().toString());
                                long diferencia = horaF.getTime() - horaI.getTime();
                                long horasD = diferencia / (1000 * 60 * 60);
                                duracionEvento.setText(String.valueOf(horasD));

                                if (cotizaciones.get(j).getClienteCompaniaRif().equals("")) {
                                    rifLabel.setText("--");
                                } else {
                                    rifLabel.setText(cotizaciones.get(j).getClienteCompaniaRif());

                                    for (int z = 0; z < companias.size(); z++) {
                                        if (cotizaciones.get(j).getClienteCompaniaRif().equals(companias.get(z).getRif())) {
                                            nombreClienteLabel.setText(companias.get(z).getNombre());
                                            direccionCliente.setText(companias.get(z).getDireccion());
                                            telefonoCliente.setText(companias.get(z).getTelefono());
                                        }
                                    }
                                }
                                if (cotizaciones.get(j).getClienteParticularCedula().equals(0)) {
                                    ciLabel.setText("--");
                                } else {
                                    ciLabel.setText(cotizaciones.get(j).getClienteParticularCedula().toString());

                                    for (int z = 0; z < particular.size(); z++) {
                                        if (cotizaciones.get(j).getClienteParticularCedula().equals(particular.get(z).getCedula())) {
                                            nombreClienteLabel.setText(particular.get(z).getNombre() + " " + particular.get(z).getApellido());
                                            direccionCliente.setText(particular.get(z).getDireccion());
                                            telefonoCliente.setText(particular.get(z).getTelefono());
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }

        } catch (IOException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }
    }

    private void asignarLabelClienteCuadre(List<Evento> eventos) {

        try {
            controlCotizacion = new ControlCotizacion();
            List<Cotizacion> cotizaciones = controlCotizacion.consultarFechaCotizaciones();

            controlClienteCompania = new ControlClienteCompania();
            List<ClienteCompania> companias = controlClienteCompania.consultarClienteCompaniaSegundaCuota();

            controlClienteParticular = new ControlClienteParticular();
            List<ClienteParticular> particular = controlClienteParticular.consultarClienteParticularSegundaCuota();

            if (idEventosCuadre.getItemCount() != 0) {
                String idTmp[] = idEventosCuadre.getSelectedItem().toString().split(", ");
                Integer id = Integer.parseInt(idTmp[0]);

                for (int i = 0; i < eventos.size(); i++) {
                    if (eventos.get(i).getIdEvento().equals(id)) {
                        for (int j = 0; j < cotizaciones.size(); j++) {
                            if (eventos.get(i).getIdEvento().equals(cotizaciones.get(j).getEventoIdEvento())) {


                                if (cotizaciones.get(j).getClienteCompaniaRif().equals("")) {
                                    rifCuadre.setText("--");
                                } else {
                                    rifCuadre.setText(cotizaciones.get(j).getClienteCompaniaRif());

                                    for (int z = 0; z < companias.size(); z++) {
                                        if (cotizaciones.get(j).getClienteCompaniaRif().equals(companias.get(z).getRif())) {
                                            nombreClienteCuadre.setText(companias.get(z).getNombre());
                                            telefonoCuadre.setText(companias.get(z).getTelefono());
                                        }
                                    }
                                }
                                if (cotizaciones.get(j).getClienteParticularCedula().equals(0)) {
                                    ciCuadre.setText("--");
                                } else {
                                    ciCuadre.setText(cotizaciones.get(j).getClienteParticularCedula().toString());

                                    for (int z = 0; z < particular.size(); z++) {
                                        if (cotizaciones.get(j).getClienteParticularCedula().equals(particular.get(z).getCedula())) {
                                            nombreClienteCuadre.setText(particular.get(z).getNombre() + " " + particular.get(z).getApellido());

                                            telefonoCuadre.setText(particular.get(z).getTelefono());
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }

        } catch (IOException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }
    }


    private void asignarLabelGastoContratados(List<Evento> eventos) {

        try {
            controlUso = new ControlUso();
            List<Uso> usos = controlUso.consultarUsoEmpleado();

            controlEmpleado = new ControlEmpleado();
            List<Empleado> empleados = controlEmpleado.consultarEmpleadoEvento();

            long horasD = 0;
            double costoHora = 0.0;
            boolean flag = false;
            if (idEventosCuadre.getItemCount() != 0) {
                String idTmp[] = idEventosCuadre.getSelectedItem().toString().split(", ");
                Integer id = Integer.parseInt(idTmp[0]);

                for (int i = 0; i < eventos.size(); i++) {
                    if (eventos.get(i).getIdEvento().equals(id)) {
                       for (int j = 0; j < usos.size(); j++) {
                            if(id.equals(usos.get(j).getEVENTO_idEVENTO())){
                                for (int k = 0; k < empleados.size(); k++) {
                                    if(usos.get(j).getEMPLEADO_cedula().equals(empleados.get(k).getCedula())){
                                        flag = true;
                                        costoHora = costoHora + empleados.get(k).getCostoHoraContratado();
                                        Time horaI = Time.valueOf(eventos.get(i).getHoraInicio().toString());
                                        Time horaF = Time.valueOf(eventos.get(i).getHoraFin().toString());
                                        long diferencia = horaF.getTime() - horaI.getTime();
                                        horasD = diferencia / (1000 * 60 * 60);
                                    }
                                }
                            }
                        }
                    }
                }
                if(flag){
                    double monto = costoHora*horasD;
                    double montoContratado = this.redondear(monto, 2);
                    gastoContratados.setText(String.valueOf(montoContratado));
                }
                if(!flag){
                    gastoContratados.setText("0.0");
                }
            }
        } catch (IOException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        } catch (SQLException ex) {
            Logger.getLogger(InformacionSistema2.class.getName()).log(Level.SEVERE, null, ex);
        }
    }

    private void asignarLabelOrdenCompra(List<Evento> eventos) {

        if (jcbEventosInsumosASubcontratar.getItemCount() != 0) {
            String[] idTmp = jcbEventosInsumosASubcontratar.getSelectedItem().toString().split(", ");
            Integer id = Integer.parseInt(idTmp[0]);
            for (int i = 0; i < eventos.size(); i++) {
                if (eventos.get(i).getIdEvento().equals(id)) {
                    fechaInsumoSubcontrato.setText(eventos.get(i).getFecha().toString());
                    horaInicioEventosInsumo.setText(eventos.get(i).getHoraInicio().toString());
                    horaFinEventosInsumo.setText(eventos.get(i).getHoraFin().toString());

                    Time horaI = Time.valueOf(eventos.get(i).getHoraInicio().toString());
                    Time horaF = Time.valueOf(eventos.get(i).getHoraFin().toString());
                    long diferencia = horaF.getTime() - horaI.getTime();
                    long horasD = diferencia / (1000 * 60 * 60);
                    duracionEventoOrden.setText(String.valueOf(horasD));
                }
            }
        } else {
            if (jcbEventosInsumosASubcontratar.getItemCount() == 0) {
                fechaInsumoSubcontrato.setText("----/--/--");
                horaInicioEventosInsumo.setText("00:00");
                horaFinEventosInsumo.setText("00:00");
                duracionEventoOrden.setText("0");
            }
        }
    }

    public static void main(String args[]) {
        java.awt.EventQueue.invokeLater(new Runnable() {

            public void run() {
                new InformacionSistema2().setVisible(true);
            }
        });
    }
    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JMenuItem acercaDe;
    private javax.swing.JMenu archivo;
    private javax.swing.ButtonGroup buttonGroup1;
    private javax.swing.JLabel cantidadEventosMes;
    private javax.swing.JLabel cantidadInsumosProveedor;
    private javax.swing.JCheckBox checkDireccion;
    private javax.swing.JCheckBox checkNombre;
    private javax.swing.JCheckBox checkTelefono;
    private javax.swing.JLabel ciCuadre;
    private javax.swing.JLabel ciEstadistica;
    private javax.swing.JLabel ciLabel;
    private javax.swing.JLabel codigoProveedorEliminar;
    private javax.swing.JLabel codigoProveedorModificar;
    private javax.swing.JTextField codigoSeguridad1;
    private javax.swing.JButton consultarEstadistica;
    private javax.swing.JLabel deposito1;
    private javax.swing.JLabel depositoCuadre;
    private javax.swing.JTextField direccion;
    private javax.swing.JLabel direccionCliente;
    private javax.swing.JTextArea direccionComp3;
    private javax.swing.JTextArea direccionProveedor;
    private javax.swing.JLabel direccionProveedorRecibo;
    private javax.swing.JLabel duracionEvento;
    private javax.swing.JLabel duracionEventoOrden;
    private javax.swing.JLabel ejecutivoEncargadoCuadre;
    private javax.swing.JLabel ejecutivoEncargadoEstadistica;
    private javax.swing.JLabel ejecutivoEncargadoLabel;
    private javax.swing.JButton eliminarProveedor;
    private javax.swing.JMenuItem exit;
    private javax.swing.JLabel fechaCotizacionLabel;
    private javax.swing.JLabel fechaEventoCuadre;
    private javax.swing.JLabel fechaEventoEstadistica;
    private javax.swing.JLabel fechaInsumoSubcontratados;
    private javax.swing.JLabel fechaInsumoSubcontrato;
    private javax.swing.JLabel fechaLabel;
    private javax.swing.JLabel gananciasPorMes;
    private javax.swing.JLabel gastoContratados;
    private javax.swing.JLabel gastoNomina;
    private javax.swing.JLabel horaFin;
    private javax.swing.JLabel horaFinCuadre;
    private javax.swing.JLabel horaFinEstadistica;
    private javax.swing.JLabel horaFinEventosInsumo;
    private javax.swing.JLabel horaFinEventosInsumoSubcontratado;
    private javax.swing.JLabel horaInicio;
    private javax.swing.JLabel horaInicioCuadre;
    private javax.swing.JLabel horaInicioEstadistica;
    private javax.swing.JLabel horaInicioEventosInsumo;
    private javax.swing.JLabel horaInicioEventosInsumoSubcontratado;
    private javax.swing.JComboBox idEventosCuadre;
    private javax.swing.JComboBox idEventosSegundaCuota;
    private javax.swing.JMenuItem informacionSistema;
    private javax.swing.JButton insertarOrdenCompra;
    private javax.swing.JButton insertarProveedor;
    private javax.swing.JLabel iva1;
    private javax.swing.JLabel ivaCuadre;
    private javax.swing.JLabel jLabel1;
    private javax.swing.JLabel jLabel10;
    private javax.swing.JLabel jLabel100;
    private javax.swing.JLabel jLabel101;
    private javax.swing.JLabel jLabel102;
    private javax.swing.JLabel jLabel103;
    private javax.swing.JLabel jLabel104;
    private javax.swing.JLabel jLabel105;
    private javax.swing.JLabel jLabel106;
    private javax.swing.JLabel jLabel107;
    private javax.swing.JLabel jLabel108;
    private javax.swing.JLabel jLabel109;
    private javax.swing.JLabel jLabel11;
    private javax.swing.JLabel jLabel110;
    private javax.swing.JLabel jLabel111;
    private javax.swing.JLabel jLabel112;
    private javax.swing.JLabel jLabel113;
    private javax.swing.JLabel jLabel115;
    private javax.swing.JLabel jLabel116;
    private javax.swing.JLabel jLabel117;
    private javax.swing.JLabel jLabel119;
    private javax.swing.JLabel jLabel12;
    private javax.swing.JLabel jLabel121;
    private javax.swing.JLabel jLabel122;
    private javax.swing.JLabel jLabel124;
    private javax.swing.JLabel jLabel125;
    private javax.swing.JLabel jLabel126;
    private javax.swing.JLabel jLabel127;
    private javax.swing.JLabel jLabel128;
    private javax.swing.JLabel jLabel129;
    private javax.swing.JLabel jLabel13;
    private javax.swing.JLabel jLabel14;
    private javax.swing.JLabel jLabel15;
    private javax.swing.JLabel jLabel16;
    private javax.swing.JLabel jLabel17;
    private javax.swing.JLabel jLabel2;
    private javax.swing.JLabel jLabel20;
    private javax.swing.JLabel jLabel23;
    private javax.swing.JLabel jLabel29;
    private javax.swing.JLabel jLabel3;
    private javax.swing.JLabel jLabel30;
    private javax.swing.JLabel jLabel31;
    private javax.swing.JLabel jLabel32;
    private javax.swing.JLabel jLabel33;
    private javax.swing.JLabel jLabel34;
    private javax.swing.JLabel jLabel36;
    private javax.swing.JLabel jLabel37;
    private javax.swing.JLabel jLabel39;
    private javax.swing.JLabel jLabel4;
    private javax.swing.JLabel jLabel40;
    private javax.swing.JLabel jLabel44;
    private javax.swing.JLabel jLabel45;
    private javax.swing.JLabel jLabel47;
    private javax.swing.JLabel jLabel48;
    private javax.swing.JLabel jLabel49;
    private javax.swing.JLabel jLabel5;
    private javax.swing.JLabel jLabel50;
    private javax.swing.JLabel jLabel51;
    private javax.swing.JLabel jLabel52;
    private javax.swing.JLabel jLabel53;
    private javax.swing.JLabel jLabel54;
    private javax.swing.JLabel jLabel55;
    private javax.swing.JLabel jLabel56;
    private javax.swing.JLabel jLabel57;
    private javax.swing.JLabel jLabel58;
    private javax.swing.JLabel jLabel59;
    private javax.swing.JLabel jLabel6;
    private javax.swing.JLabel jLabel60;
    private javax.swing.JLabel jLabel61;
    private javax.swing.JLabel jLabel62;
    private javax.swing.JLabel jLabel63;
    private javax.swing.JLabel jLabel64;
    private javax.swing.JLabel jLabel65;
    private javax.swing.JLabel jLabel66;
    private javax.swing.JLabel jLabel67;
    private javax.swing.JLabel jLabel68;
    private javax.swing.JLabel jLabel69;
    private javax.swing.JLabel jLabel7;
    private javax.swing.JLabel jLabel70;
    private javax.swing.JLabel jLabel71;
    private javax.swing.JLabel jLabel72;
    private javax.swing.JLabel jLabel73;
    private javax.swing.JLabel jLabel74;
    private javax.swing.JLabel jLabel75;
    private javax.swing.JLabel jLabel76;
    private javax.swing.JLabel jLabel77;
    private javax.swing.JLabel jLabel78;
    private javax.swing.JLabel jLabel79;
    private javax.swing.JLabel jLabel8;
    private javax.swing.JLabel jLabel80;
    private javax.swing.JLabel jLabel81;
    private javax.swing.JLabel jLabel82;
    private javax.swing.JLabel jLabel83;
    private javax.swing.JLabel jLabel84;
    private javax.swing.JLabel jLabel85;
    private javax.swing.JLabel jLabel86;
    private javax.swing.JLabel jLabel87;
    private javax.swing.JLabel jLabel88;
    private javax.swing.JLabel jLabel89;
    private javax.swing.JLabel jLabel9;
    private javax.swing.JLabel jLabel90;
    private javax.swing.JLabel jLabel91;
    private javax.swing.JLabel jLabel92;
    private javax.swing.JLabel jLabel93;
    private javax.swing.JLabel jLabel94;
    private javax.swing.JLabel jLabel95;
    private javax.swing.JLabel jLabel96;
    private javax.swing.JLabel jLabel97;
    private javax.swing.JLabel jLabel98;
    private javax.swing.JLabel jLabel99;
    private javax.swing.JMenu jMenu1;
    private javax.swing.JMenuBar jMenuBar1;
    private javax.swing.JMenuItem jMenuItem2;
    private javax.swing.JPanel jPanel1;
    private javax.swing.JPanel jPanel10;
    private javax.swing.JPanel jPanel11;
    private javax.swing.JPanel jPanel12;
    private javax.swing.JPanel jPanel13;
    private javax.swing.JPanel jPanel15;
    private javax.swing.JPanel jPanel16;
    private javax.swing.JPanel jPanel17;
    private javax.swing.JPanel jPanel18;
    private javax.swing.JPanel jPanel19;
    private javax.swing.JPanel jPanel2;
    private javax.swing.JPanel jPanel20;
    private javax.swing.JPanel jPanel21;
    private javax.swing.JPanel jPanel22;
    private javax.swing.JPanel jPanel23;
    private javax.swing.JPanel jPanel24;
    private javax.swing.JPanel jPanel25;
    private javax.swing.JPanel jPanel26;
    private javax.swing.JPanel jPanel27;
    private javax.swing.JPanel jPanel28;
    private javax.swing.JPanel jPanel29;
    private javax.swing.JPanel jPanel3;
    private javax.swing.JPanel jPanel30;
    private javax.swing.JPanel jPanel31;
    private javax.swing.JPanel jPanel32;
    private javax.swing.JPanel jPanel33;
    private javax.swing.JPanel jPanel34;
    private javax.swing.JPanel jPanel35;
    private javax.swing.JPanel jPanel38;
    private javax.swing.JPanel jPanel4;
    private javax.swing.JPanel jPanel5;
    private javax.swing.JPanel jPanel6;
    private javax.swing.JPanel jPanel8;
    private javax.swing.JPanel jPanel9;
    private javax.swing.JScrollPane jScrollPane1;
    private javax.swing.JScrollPane jScrollPane12;
    private javax.swing.JScrollPane jScrollPane13;
    private javax.swing.JScrollPane jScrollPane14;
    private javax.swing.JScrollPane jScrollPane15;
    private javax.swing.JScrollPane jScrollPane3;
    private javax.swing.JScrollPane jScrollPane4;
    private javax.swing.JScrollPane jScrollPane5;
    private javax.swing.JScrollPane jScrollPane6;
    private javax.swing.JScrollPane jScrollPane7;
    private javax.swing.JScrollPane jScrollPane8;
    private javax.swing.JSeparator jSeparator1;
    private javax.swing.JTabbedPane jTabbedPane1;
    private javax.swing.JComboBox jcbEventosInsumosASubcontratar;
    private javax.swing.JComboBox jcbInsumosSubcontratados;
    private javax.swing.JComboBox jcbProveedoresCuadre;
    private javax.swing.JComboBox jcbProveedoresRecibo;
    private javax.swing.JLabel labelCancelado1;
    private javax.swing.JLabel labelGanadoPerdido;
    private javax.swing.JLabel labelTotalInsumos;
    private javax.swing.JButton limpiar;
    private javax.swing.JButton limpiar11;
    private javax.swing.JButton limpiar12;
    private javax.swing.JLabel lugarEvento;
    private javax.swing.JButton modificarProveedor;
    private com.toedter.calendar.JMonthChooser monthChooser;
    private javax.swing.JLabel montoCotizadoPorMes;
    private javax.swing.JLabel montoSubcontratadoPorMes;
    private javax.swing.JLabel montoTotalGanado;
    private javax.swing.JLabel montoTotalPerdido;
    private javax.swing.JButton mostrarCuadreGanancia;
    private javax.swing.JButton mostrarFacturas;
    private javax.swing.JButton mostrarOrdenCompra;
    private javax.swing.JButton mostrarProveedores;
    private javax.swing.JButton mostrarReciboPago;
    private javax.swing.JTextField nombre;
    private javax.swing.JTextField nombre2;
    private javax.swing.JTextField nombre4;
    private javax.swing.JTextField nombreBanco1;
    private javax.swing.JTextField nombreBancoCheque1;
    private javax.swing.JLabel nombreClienteCuadre;
    private javax.swing.JLabel nombreClienteEstadistica;
    private javax.swing.JLabel nombreClienteLabel;
    private javax.swing.JLabel nombreProveedor;
    private javax.swing.JLabel nroFacturaLabel;
    private javax.swing.JMenuItem nuevaCotizacion;
    private javax.swing.JTextField numeroCheque1;
    private javax.swing.JTextField numeroTarjeta1;
    private javax.swing.JLabel otrosGastos;
    private javax.swing.JLabel pagoTotalLabel;
    private javax.swing.JLabel pagoTotalLabelCuadre;
    private javax.swing.JLabel perdidasPorMes;
    private javax.swing.JLabel rifCuadre;
    private javax.swing.JLabel rifLabel;
    private javax.swing.JButton salir;
    private javax.swing.JLabel subtotal1;
    private javax.swing.JLabel subtotalCuadre;
    private javax.swing.JTable tablaEmpleadosContratados;
    private javax.swing.JTable tablaEstadisticas;
    private javax.swing.JTable tablaFactura;
    private javax.swing.JTable tablaFacturaCuadre;
    private javax.swing.JTable tablaInsumosASubcontratar;
    private javax.swing.JTable tablaInsumosSubcontratados;
    private javax.swing.JTable tablaInsumosSubcontratadosCuadre;
    private javax.swing.JTable tablaProveedor;
    private javax.swing.JTable tablaProveedores;
    private javax.swing.JTextField telefono;
    private javax.swing.JLabel telefonoCliente;
    private javax.swing.JLabel telefonoCuadre;
    private javax.swing.JLabel telefonoEstadistica;
    private javax.swing.JLabel telefonoProveedor;
    private javax.swing.JLabel telefonoProveedorRecibo;
    private javax.swing.JComboBox tipoCtaCombo1;
    private javax.swing.JComboBox tipoPagoCombo1;
    private javax.swing.JComboBox tipoTarjetaCombo1;
    private javax.swing.JLabel totalInsumoFacturado;
    private javax.swing.JLabel totalInsumoSubcontratado;
    private javax.swing.JLabel totalPagoPorInsumo;
    private javax.swing.JLabel totalPagoPorProveedorCuadre;
    private javax.swing.JLabel totalPagoPorProveedorRecibo;
    private javax.swing.JLabel totalSubcontratadoRecibo;
    private org.jdesktop.beansbinding.BindingGroup bindingGroup;
    // End of variables declaration//GEN-END:variables
}
